summaryrefslogtreecommitdiff
path: root/hosts/cloud/oldsortug/nginx.nix
blob: ba64539da2d2091f4fcd4679e740b500a2bd8455 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
{ ... }: {

  security.acme.acceptTerms = true;
  security.acme.defaults.email = "security@sortug.com";
  users.users.y.homeMode = "750";
  services.nginx = {
    enable = true;
    virtualHosts."old.sortug.com" =  {
      enableACME = true;
      forceSSL = true;
      locations."/" = {
        proxyPass = "http://127.0.0.1:9000";
        proxyWebsockets = true; # needed if you need to use WebSocket
        extraConfig = ''
         proxy_set_header Host $Host;
        '';
        # actually important
      };
    };
  };
}