diff options
| author | Xe Iaso <me@xeiaso.net> | 2025-03-29 20:12:35 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-03-29 20:12:35 -0400 |
| commit | 168329fff02bd86af1ef7eb2728b772fb9535478 (patch) | |
| tree | 30364ba7b730c253e208c0a5af650fa8bd73907c /docs | |
| parent | 52ca5390c2b54374e62cbcd2efaf78edaa4e7249 (diff) | |
| download | anubis-168329fff02bd86af1ef7eb2728b772fb9535478.tar.xz anubis-168329fff02bd86af1ef7eb2728b772fb9535478.zip | |
docs/developer: add build directions for manually building Anubis (#154)
Signed-off-by: Xe Iaso <me@xeiaso.net>
Diffstat (limited to 'docs')
| -rw-r--r-- | docs/docs/developer/building-anubis.md | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/docs/docs/developer/building-anubis.md b/docs/docs/developer/building-anubis.md new file mode 100644 index 0000000..157ff8d --- /dev/null +++ b/docs/docs/developer/building-anubis.md @@ -0,0 +1,41 @@ +--- +title: Building Anubis without Docker +--- + +:::note + +These instructions may work, but for right now they are informative for downstream packagers more than they are ready-made instructions for administrators wanting to run Anubis on their servers. + +:::end + +## Tools needed + +In order to build a production-ready binary of Anubis, you need the following packages in your environment: + +- [Go](https://go.dev) - the programming language that Anubis is written in +- [esbuild](https://esbuild.github.io/) - the JavaScript bundler Anubis uses for its production JS assets +- [Node.JS & NPM](https://nodejs.org/en) - manages some build dependencies +- `gzip` - compresses production JS (part of coreutils) +- `zstd` - compresses production JS +- `brotli` - compresses production JS + +## Install dependencies + +```text +go mod download +npm ci +``` + +## Building static assets + +```text +npm run assets +``` + +## Building Anubis to the `./var` folder + +```text +go build -o ./var/anubis ./cmd/anubis +``` + +From this point it is up to you to make sure that `./var/anubis` ends up in the right place. You may want to consult the `./run` folder for useful files such as a systemd unit and `anubis.env.default` file. |
