nixos/modules/binary-cache.nix

21 lines
587 B
Nix

{
pkgs,
config,
...
}: {
services.nginx.virtualHosts."cache.home.dyn.tammena.rocks" = {
serverAliases = ["cache.elysia-clarki"];
locations."/" = {
proxyPass = "http://localhost:${builtins.toString config.services.nix-serve.port}";
extraConfig = ''
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
'';
};
# This needs reachability over the inter-webs, which is currently limited to IPv6
enableACME = false;
forceSSL = false;
};
}