diff options
Diffstat (limited to 'hosts/kay/modules/www.nix')
-rw-r--r-- | hosts/kay/modules/www.nix | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/hosts/kay/modules/www.nix b/hosts/kay/modules/www.nix index 08548e8..521bd6e 100644 --- a/hosts/kay/modules/www.nix +++ b/hosts/kay/modules/www.nix @@ -3,6 +3,7 @@ let domain = config.userdata.domain; email = config.userdata.email; + fscusat = "fscusat.org"; in { imports = [ @@ -42,6 +43,24 @@ in enableACME = true; root = "/var/www/${domain}"; }; + "${fscusat}" = { + forceSSL = true; + enableACME = true; + globalRedirect = "www.${fscusat}"; + }; + "www.${fscusat}" = { + forceSSL = true; + enableACME = true; + extraConfig = '' + proxy_set_header Host $host; + proxy_set_header X-Real-IP $remote_addr; + proxy_read_timeout 600; + ''; + + locations."/" = { + proxyPass = "http://10.0.1.4:80"; + }; + }; }; }; } |