mirror of
https://github.com/CHN-beta/nixos.git
synced 2026-01-12 04:19:22 +08:00
enable proxyProtocol as default
This commit is contained in:
@@ -283,7 +283,7 @@
|
||||
"anchor.fm" = { upstream = "anchor.fm:443"; proxyProtocol = false; };
|
||||
"podcasters.spotify.com" = { upstream = "podcasters.spotify.com:443"; proxyProtocol = false; };
|
||||
"xlog.chn.moe" = { upstream = "cname.xlog.app:443"; proxyProtocol = false; };
|
||||
"nix-store.chn.moe" = { upstream = "internal.pc.chn.moe"; proxyProtocol = false; };
|
||||
"nix-store.chn.moe".upstream.address = "internal.pc.chn.moe";
|
||||
"xn--qbtm095lrg0bfka60z.chn.moe".upstream.address = "internal.pc.chn.moe";
|
||||
"xn--s8w913fdga.chn.moe".upstream.address = "internal.vps7.chn.moe";
|
||||
"misskey.chn.moe".upstream.address = "internal.vps7.chn.moe";
|
||||
|
||||
@@ -167,15 +167,7 @@ inputs:
|
||||
(instance: with instance.value;
|
||||
{
|
||||
name = hostname;
|
||||
value =
|
||||
{
|
||||
listen.main.proxyProtocol = true;
|
||||
location."/".proxy =
|
||||
{
|
||||
upstream = "http://127.0.0.1:${toString port}";
|
||||
websocket = true;
|
||||
};
|
||||
};
|
||||
value.location."/".proxy = { upstream = "http://127.0.0.1:${toString port}"; websocket = true; };
|
||||
})
|
||||
(attrsToList misskey.instances));
|
||||
};
|
||||
|
||||
@@ -73,7 +73,7 @@ inputs:
|
||||
type = types.attrsOf (types.submodule { options =
|
||||
{
|
||||
http2 = mkOption { type = types.bool; default = true; };
|
||||
proxyProtocol = mkOption { type = types.bool; default = false; };
|
||||
proxyProtocol = mkOption { type = types.bool; default = true; };
|
||||
# if proxyProtocol not enabled, add to transparentProxy only
|
||||
# if proxyProtocol enabled, add to transparentProxy and streamProxy
|
||||
addToTransparentProxy = mkOption { type = types.bool; default = true; };
|
||||
|
||||
@@ -47,11 +47,7 @@ inputs:
|
||||
nginx =
|
||||
{
|
||||
enable = true;
|
||||
https."${send.hostname}" =
|
||||
{
|
||||
listen.main.proxyProtocol = true;
|
||||
location."/".proxy = { upstream = "http://127.0.0.1:1443"; websocket = true; };
|
||||
};
|
||||
https."${send.hostname}".location."/".proxy = { upstream = "http://127.0.0.1:1443"; websocket = true; };
|
||||
};
|
||||
redis.instances.send = { user = "root"; port = 9184; };
|
||||
};
|
||||
|
||||
@@ -102,15 +102,8 @@ inputs:
|
||||
nginx =
|
||||
{
|
||||
enable = true;
|
||||
https.${synapse.hostname} =
|
||||
{
|
||||
listen.main.proxyProtocol = true;
|
||||
location."/".proxy =
|
||||
{
|
||||
upstream = "http://127.0.0.1:${toString synapse.port}";
|
||||
websocket = true;
|
||||
};
|
||||
};
|
||||
https.${synapse.hostname}.location."/".proxy =
|
||||
{ upstream = "http://127.0.0.1:${toString synapse.port}"; websocket = true; };
|
||||
};
|
||||
};
|
||||
systemd.services.matrix-synapse.enable = synapse.autoStart;
|
||||
|
||||
Reference in New Issue
Block a user