fix xray server

This commit is contained in:
陈浩南 2023-08-10 19:55:08 +08:00
parent e72fe79441
commit 725adb574c

View File

@ -432,6 +432,8 @@ inputs:
xray = { enable = true; settingsFile = inputs.config.sops.templates."xray-server.json".path; }; xray = { enable = true; settingsFile = inputs.config.sops.templates."xray-server.json".path; };
nginx.virtualHosts.xserver = nginx.virtualHosts.xserver =
{ {
serverName = services.xrayServer.serverName;
default = true;
listen = [{ addr = "127.0.0.1"; port = 7233; }]; listen = [{ addr = "127.0.0.1"; port = 7233; }];
locations."/".return = "400"; locations."/".return = "400";
}; };
@ -511,7 +513,7 @@ inputs:
nginx.transparentProxy = nginx.transparentProxy =
{ {
enable = true; enable = true;
map."xserver.chn.moe" = "4726"; map."${services.xrayServer.serverName}" = "4726";
proxyPorts = [ 4726 ]; proxyPorts = [ 4726 ];
}; };
}; };