From cd942d253bda8f511fdb921ea29f69f382a9368e Mon Sep 17 00:00:00 2001 From: sinanmohd Date: Fri, 8 Mar 2024 10:50:28 +0530 Subject: repo: restructure source tree --- hosts/fscusat/modules/www.nix | 36 ------------------------------------ 1 file changed, 36 deletions(-) delete mode 100644 hosts/fscusat/modules/www.nix (limited to 'hosts/fscusat/modules/www.nix') diff --git a/hosts/fscusat/modules/www.nix b/hosts/fscusat/modules/www.nix deleted file mode 100644 index 24398da..0000000 --- a/hosts/fscusat/modules/www.nix +++ /dev/null @@ -1,36 +0,0 @@ -{ config, ... }: - -let - domain = "foss.fscusat.ac.in"; -in -{ - networking.firewall.allowedTCPPorts = [ 80 443 ]; - - sops.secrets = let - opts = { - owner = config.services.nginx.user; - group = config.services.nginx.group; - }; - in{ - "cusat.ac.in/key" = opts; - "cusat.ac.in/crt" = opts; - }; - - services.nginx = { - enable = true; - recommendedTlsSettings = true; - recommendedZstdSettings = true; - recommendedOptimisation = true; - recommendedGzipSettings = true; - recommendedProxySettings = true; - recommendedBrotliSettings = true; - - virtualHosts.${domain} = { - forceSSL = true; - sslCertificateKey = config.sops.secrets."cusat.ac.in/key".path; - sslCertificate = config.sops.secrets."cusat.ac.in/crt".path; - - locations."/".extraConfig = "return 307 $scheme://$host/mirror/;"; - }; - }; -} -- cgit v1.2.3