forked from fi/nix-infra
Initial commit
This commit is contained in:
commit
6f88b92591
20 changed files with 395 additions and 0 deletions
29
hosts/nitter/nginx.nix
Normal file
29
hosts/nitter/nginx.nix
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
{ ... }:
|
||||
{
|
||||
services.nginx = {
|
||||
enable = true;
|
||||
enableReload = true;
|
||||
recommendedGzipSettings = true;
|
||||
recommendedOptimisation = true;
|
||||
recommendedProxySettings = true;
|
||||
recommendedTlsSettings = true;
|
||||
|
||||
virtualHosts = {
|
||||
"nixos-nitter.vs.grzb.de" = {
|
||||
locations."/robots.txt" = {
|
||||
return = "200 \"User-agent: *\\nDisallow: /\\n\"";
|
||||
};
|
||||
|
||||
locations."/" = {
|
||||
proxyPass = "http://localhost:8080";
|
||||
extraConfig =
|
||||
"proxy_http_version 1.1;" +
|
||||
"proxy_set_header Upgrade $http_upgrade;" +
|
||||
"proxy_set_header Connection \"upgrade\";" +
|
||||
"proxy_set_header Host $host;"
|
||||
;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue