This commit is contained in:
parent
d775214e1b
commit
5f14e07921
@ -8,17 +8,19 @@ server {
|
||||
# 前端打包好的dist目录文件
|
||||
root /data/;
|
||||
|
||||
location / {
|
||||
try_files $uri $uri/ /index.html;
|
||||
}
|
||||
|
||||
# 若新增后端路由前缀注意在此处添加(|新增)
|
||||
location ~* ^/(api) {
|
||||
client_max_body_size 1000m;
|
||||
proxy_pass http://wireguard-srv:6687;
|
||||
# proxy_connect_timeout 15s;
|
||||
# proxy_send_timeout 15s;
|
||||
# proxy_read_timeout 15s;
|
||||
proxy_set_header X-Forwarded-Proto $scheme;
|
||||
proxy_set_header Host $http_host;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
proxy_set_header X-Forwarded-Proto http;
|
||||
location ^~ /api/ {
|
||||
proxy_pass http://wiregiard-srv:6687/;
|
||||
proxy_set_header Host $host;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
proxy_set_header REMOTE-HOST $remote_addr;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection "upgrade";
|
||||
proxy_set_header X-Forwarded-Proto $scheme;
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user