diff --git a/docs/mkdocs.yml b/docs/mkdocs.yml index c80ca7e..e3564ff 100644 --- a/docs/mkdocs.yml +++ b/docs/mkdocs.yml @@ -62,6 +62,7 @@ nav: - Getting Started: - Overview: getting-started/overview.md - Usage: + - Setup: usage/setup.md - Configure pool: usage/configure-pool.md - Generating keys: usage/generate-keys.md - Deploy: usage/deploy.md diff --git a/docs/usage/setup.md b/docs/usage/setup.md new file mode 100644 index 0000000..3555267 --- /dev/null +++ b/docs/usage/setup.md @@ -0,0 +1,28 @@ +## Installation + +Follow [this guide](https://zero-to-nix.com/start/install) to Install nix with [flakes](https://nix.dev/concepts/flakes.html) enabled. + +### Binary cache + +You can optionally use this project's binary cache to skip building software and download it instead. Edit `/etc/nix/nix.conf` (or related settings in NixOS config) and merge the new values separated by spaces into the options: + +``` +substituters = ... https://cache.staging.mlabs.city/spo-anywhere +trusted-public-keys = ... spo-anywhere:bmI58BmXnmeuAtMKbm3qhwiJ1RALMfo6cDwncfaGa6Q= +``` + +## Start new project from flake + +Create a new directory, enter it, and initialize a new project form the spo-anywhere flake template. + +``` +mkdir my-spo +cd my-spo +nix flake init --template github:mlabs-haskell/spo-anywhere +``` + +Check that the installation script starts: + +``` +nix run .#install -- -h +```