aboutsummaryrefslogtreecommitdiff
path: root/doc/manual/src/package-management/binary-cache-substituter.md
diff options
context:
space:
mode:
Diffstat (limited to 'doc/manual/src/package-management/binary-cache-substituter.md')
-rw-r--r--doc/manual/src/package-management/binary-cache-substituter.md24
1 files changed, 18 insertions, 6 deletions
diff --git a/doc/manual/src/package-management/binary-cache-substituter.md b/doc/manual/src/package-management/binary-cache-substituter.md
index 855eaf470..4dcf2ca3f 100644
--- a/doc/manual/src/package-management/binary-cache-substituter.md
+++ b/doc/manual/src/package-management/binary-cache-substituter.md
@@ -1,8 +1,21 @@
# Serving a Nix store via HTTP
+<div class="warning">
+
+FIXME(Lix): This section documents outdated practices.
+
+In particular, the Lix developers would *not* recommend using `nix-serve` as it is relatively-unmaintained Perl.
+The Lix developers would recommend instead using an s3 based cache (which is what https://cache.nixos.org is), and if it is desired to self-host it, use something like [garage](https://garagehq.deuxfleurs.fr/).
+
+See the following projects:
+- [attic](https://github.com/zhaofengli/attic) - multi-tenant cache for larger deployments, using s3 as a backend.
+- [harmonia](https://github.com/nix-community/harmonia) - closer to a drop in replacement for use cases served by nix-serve
+
+</div>
+
You can easily share the Nix store of a machine via HTTP. This allows
other machines to fetch store paths from that machine to speed up
-installations. It uses the same *binary cache* mechanism that Nix
+installations. It uses the same *binary cache* mechanism that Lix
usually uses to fetch pre-built binaries from <https://cache.nixos.org>.
The daemon that handles binary cache requests via HTTP, `nix-serve`, is
@@ -31,20 +44,19 @@ which should print something like:
WantMassQuery: 1
Priority: 30
-On the client side, you can tell Nix to use your binary cache using
-`--substituters`, e.g.:
+On the client side, you can tell Lix to use your binary cache using `--substituters` (assuming you are a trusted user, see `trusted-users` in nix.conf), e.g.:
```console
$ nix-env --install --attr nixpkgs.firefox --substituters http://avalon:8080/
```
-The option `substituters` tells Nix to use this binary cache in
+The option `substituters` tells Lix to use this binary cache in
addition to your default caches, such as <https://cache.nixos.org>.
-Thus, for any path in the closure of Firefox, Nix will first check if
+Thus, for any path in the closure of Firefox, Lix will first check if
the path is available on the server `avalon` or another binary caches.
If not, it will fall back to building from source.
-You can also tell Nix to always use your binary cache by adding a line
+You can also tell Lix to always use your binary cache by adding a line
to the `nix.conf` configuration file like this:
substituters = http://avalon:8080/ https://cache.nixos.org/