diff options
| author | Ben Busby <contact@benbusby.com> | 2023-03-22 11:56:22 -0600 |
|---|---|---|
| committer | Ben Busby <contact@benbusby.com> | 2023-03-22 11:56:22 -0600 |
| commit | 9eb11ed2645d30e81d89c8cfd53a4935b3167c10 (patch) | |
| tree | 2b2bf58e5022a60b006cd87797b441d57cf68541 /README.md | |
| parent | b75355ed758201a7e2280cb7b3350407ee269d57 (diff) | |
| download | farside-9eb11ed2645d30e81d89c8cfd53a4935b3167c10.tar.gz | |
Allow compiling to standalone binary via bakeware
This introduces a simple way of compiling Farside to a somewhat portable,
standalone binary. The resulting binary isn't completely portable since it
depends on the C runtime of the host system. As a result, it's advised to use
systems with older library versions when compiling for true portability.
Closes #50
Co-authored-by: Jason Clark <mithereal@gmail.com>
Diffstat (limited to 'README.md')
| -rw-r--r-- | README.md | 29 |
1 files changed, 29 insertions, 0 deletions
@@ -18,6 +18,17 @@ </div> +Contents +1. [About](#about) +2. [Demo](#demo) +3. [How It Works](#how-it-works) +4. [Cloudflare](#regarding-cloudflare) +5. [Development](#development) + 1. [Compiling](#compiling) + 1. [Environment Variables](#environment-variables) + +## About + A redirecting service for FOSS alternative frontends. [Farside](https://farside.link) provides links that automatically redirect to @@ -178,11 +189,29 @@ goes against what Farside is trying to solve. Use at your own discretion. ## Development - Install [elixir](https://elixir-lang.org/install.html) - (on Debian systems) Install [erlang-dev](https://packages.debian.org/sid/erlang-dev) + +To run Farside without compiling, you can perform the following steps: + - Install dependencies: `mix deps.get` - Initialize db contents: `mix run -e Farside.Instances.sync` - Run Farside: `mix run --no-halt` - Uses localhost:4001 +### Compiling + +You can create a standalone Farside app using the steps below. In the example, the +Farside executable is copied to `/usr/local/bin`, but can be moved to any preferred +destination. Note that the executable still depends on the C runtime of the machine +it is built on, so if you want a more portable binary, you should build Farside on a +system with older library versions. + +``` +MIX_ENV=cli && mix deps.get && mix release +cp _build/cli/rel/bakeware/farside /usr/local/bin +sudo chmod +x /usr/local/bin/farside +farside +``` + ### Environment Variables <table> |
