feat(caddy): install and replace nginx
This commit is contained in:
parent
500c704cf4
commit
33af7eaadf
27 changed files with 212 additions and 158 deletions
|
|
@ -7,6 +7,7 @@
|
|||
}:
|
||||
let
|
||||
port = 5000;
|
||||
certloc = "/var/lib/acme/fi33.buzz";
|
||||
in
|
||||
{
|
||||
imports = [ inputs.copyparty.nixosModules.default ];
|
||||
|
|
@ -33,11 +34,12 @@ in
|
|||
};
|
||||
};
|
||||
|
||||
nginx.virtualHosts."copyparty.fi33.buzz" = {
|
||||
forceSSL = true;
|
||||
useACMEHost = "fi33.buzz";
|
||||
locations."/".proxyPass = "http://localhost:${toString port}";
|
||||
};
|
||||
caddy.virtualHosts."copyparty.fi33.buzz".extraConfig = ''
|
||||
reverse_proxy localhost:${toString port}
|
||||
tls ${certloc}/cert.pem ${certloc}/key.pem {
|
||||
protocols tls1.3
|
||||
}
|
||||
'';
|
||||
};
|
||||
|
||||
# secrets
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue