services: use explicit loopback address w/ vhosts

Otherwise it can result in failure to proxy requests sometimes...
This commit is contained in:
Bruno BELANYI 2021-03-27 15:48:49 +00:00
parent 9155e139d4
commit 7fc3a74329
10 changed files with 11 additions and 11 deletions

View file

@ -46,7 +46,7 @@ in
forceSSL = true; forceSSL = true;
useACMEHost = domain; useACMEHost = domain;
locations."/".proxyPass = "http://localhost:${toString cfg.port}/"; locations."/".proxyPass = "http://127.0.0.1:${toString cfg.port}/";
}; };
my.services.backup = { my.services.backup = {

View file

@ -113,7 +113,7 @@ in
forceSSL = true; forceSSL = true;
useACMEHost = domain; useACMEHost = domain;
locations."/".proxyPass = "http://localhost:${toString cfg.port}"; locations."/".proxyPass = "http://127.0.0.1:${toString cfg.port}";
}; };
# Docker runner # Docker runner

View file

@ -64,7 +64,7 @@ in
forceSSL = true; forceSSL = true;
useACMEHost = domain; useACMEHost = domain;
locations."/".proxyPass = "http://localhost:${toString cfg.port}/"; locations."/".proxyPass = "http://127.0.0.1:${toString cfg.port}/";
}; };
my.services.backup = { my.services.backup = {

View file

@ -26,7 +26,7 @@ in
forceSSL = true; forceSSL = true;
useACMEHost = domain; useACMEHost = domain;
locations."/".proxyPass = "http://localhost:${toString jackettPort}/"; locations."/".proxyPass = "http://127.0.0.1:${toString jackettPort}/";
}; };
services.nzbhydra2 = lib.mkIf cfg.nzbhydra.enable { services.nzbhydra2 = lib.mkIf cfg.nzbhydra.enable {
@ -38,7 +38,7 @@ in
forceSSL = true; forceSSL = true;
useACMEHost = domain; useACMEHost = domain;
locations."/".proxyPass = "http://localhost:${toString nzbhydraPort}/"; locations."/".proxyPass = "http://127.0.0.1:${toString nzbhydraPort}/";
}; };
}; };
} }

View file

@ -22,7 +22,7 @@ in
useACMEHost = domain; useACMEHost = domain;
locations."/" = { locations."/" = {
proxyPass = "http://localhost:8096/"; proxyPass = "http://127.0.0.1:8096/";
proxyWebsockets = true; proxyWebsockets = true;
}; };
}; };

View file

@ -61,7 +61,7 @@ in
forceSSL = true; forceSSL = true;
useACMEHost = domain; useACMEHost = domain;
locations."/".proxyPass = "http://localhost:${toString cfg.privatePort}/"; locations."/".proxyPass = "http://127.0.0.1:${toString cfg.privatePort}/";
}; };
}; };
} }

View file

@ -63,7 +63,7 @@ in
forceSSL = true; forceSSL = true;
useACMEHost = domain; useACMEHost = domain;
locations."/".proxyPass = "http://localhost:3000/"; locations."/".proxyPass = "http://127.0.0.1:3000/";
}; };
my.services.backup = { my.services.backup = {

View file

@ -28,7 +28,7 @@ let
forceSSL = true; forceSSL = true;
useACMEHost = domain; useACMEHost = domain;
locations."/".proxyPass = "http://localhost:${builtins.toString port}/"; locations."/".proxyPass = "http://127.0.0.1:${builtins.toString port}/";
}) })
ports); ports);
in in

View file

@ -22,7 +22,7 @@ in
forceSSL = true; forceSSL = true;
useACMEHost = domain; useACMEHost = domain;
locations."/".proxyPass = "http://localhost:${toString port}"; locations."/".proxyPass = "http://127.0.0.1:${toString port}";
}; };
}; };
} }

View file

@ -81,7 +81,7 @@ in
forceSSL = true; forceSSL = true;
useACMEHost = domain; useACMEHost = domain;
locations."/".proxyPass = "http://localhost:${toString cfg.privatePort}"; locations."/".proxyPass = "http://127.0.0.1:${toString cfg.privatePort}";
}; };
networking.firewall = { networking.firewall = {