Skip to content
/ fastside Public

A smart redirecting gateway for various frontend services. Faster alternative to farside.

License

Notifications You must be signed in to change notification settings

cofob/fastside

Repository files navigation

fastside

A smart redirecting gateway for various frontend services. Faster and compatible alternative to farside.

Contents

About

A redirecting service for FOSS alternative frontends.

Fastside provides links that automatically redirect to working instances of privacy-oriented alternative frontends, such as Nitter, Libreddit, etc. This allows for users to have more reliable access to the available public instances for a particular service, while also helping to distribute traffic more evenly across all instances and avoid performance bottlenecks and rate-limiting.

Features

  • Support for hidden networks (tor, i2p, etc).
  • Redirect behaviour can be configured. (for example - you can exclude cloudflare)
  • User-preferred instances.
  • POST redirects.
  • Regex redirects via /{url} routes.
  • Anonymous and cached redirects via /@cached/#{path} routes.
  • History redirects via /_/{path} routes.
  • Fallback redirects.
  • Automatic update of services list.
  • API.

Demo

Fastside's links work with the following structure: fastsi.de/<service>/<path>

For example:

Service Page Fastside Link
Libreddit /r/popular https://fastsi.de/libreddit/r/popular
Teddit /r/popular https://fastsi.de/teddit/r/popular
Invidious /watch?v=zLGDE2j_n5c https://fastsi.de/_/invidious/watch?v=zLGDE2j_n5c
Invidious https://www.youtube.com/watch?v=zLGDE2j_n5c https://fastsi.de/https://www.youtube.com/watch?v=zLGDE2j_n5c
AnonymousOverflow /questions/1732348/regex-match-open-tags-except-xhtml-self-contained-tags https://fastsi.de/@cached/anonymousoverflow/#questions/1732348/regex-match-open-tags-except-xhtml-self-contained-tags

Note: This table doesn't include all available services. For a complete list of supported frontends, see: https://fastsi.de/

Mirrors

Fastside can be opened in clearnet, clearnet cloudflare, tor, i2p (b32), yggdrasil (Alfis, IPv6).

How It Works

The app runs with an internally scheduled cron task that queries all instances for services defined in services.json every 5 minutes. For each instance, as long as the instance takes <5 seconds to respond and returns a successful response code, the instance is added to a list of available instances for that particular service. If not, it is discarded until the next update period.

Fastside's routing is minimal, similar to Farside, but includes an additional /@cached/<service>#<path> endpoint, which utilizes browser caching to achieve instant redirects without waiting for server responses.

Self-Hosting

Setting up Fastside on your server is straightforward with Docker. Simply execute the following command:

docker run --restart unless-stopped --name fastside -d -p 8080:8080 ghcr.io/cofob/fastside

This will deploy Fastside, making it accessible on port 8080 of your server. The service will automatically use the default services.json as its configuration source.

Compiling from Source

If you prefer to compile Fastside from source, ensure you have Rust's package manager, Cargo, installed. Then, navigate to the repository and run the following command:

cargo build --release

The compiled executables will be located in the target/release directory.

Why does this fork exist?

Farside operates very slowly for some reason. The ping from my machine to their server in the USA is 300 ms, and a redirect request takes about 1 second to process (!). This means that processing a redirect takes 700 ms, which is incredibly long for such a simple task. On the other hand, Fastside processes requests in 200-300 ms (taking my internet into account). Additionally, the web server at fastside.link supports http3, which saves us an additional 100-150 ms.

Migration from farside

Migrating from farside to fastside is very simple - just replace the redirects from farside.link to fastside.link.

Tips and tricks

Use fastside to upload files to 0x0

curl -LF'[email protected]' fastsi.de/0x0

About

A smart redirecting gateway for various frontend services. Faster alternative to farside.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages