nginx conf update

This commit is contained in:
qiaofeng1227 2023-09-20 09:53:00 +08:00
parent d696053ee9
commit 90e6d20c46

View File

@ -2,7 +2,6 @@
# domain.com # domain.com
# ------------------------------------------------------------ # ------------------------------------------------------------
server { server {
listen 80; listen 80;
@ -13,15 +12,14 @@ server {
access_log /data/logs/proxy-host-1_access.log proxy; access_log /data/logs/proxy-host-1_access.log proxy;
error_log /data/logs/proxy-host-1_error.log warn; error_log /data/logs/proxy-host-1_error.log warn;
if ($http_referer ~* /portainer/) { if ($http_referer ~* /w9deployment/) {
rewrite ^/locales/(.*) /portainer/locales/$1 break; rewrite ^/locales/(.*) /w9deployment/locales/$1 break;
} }
location / { location / {
# Proxy! # Proxy!
include conf.d/include/proxy.conf; include conf.d/include/proxy.conf;
} }
# proxy for portainer # proxy for portainer
location /w9deployment/ { location /w9deployment/ {
@ -49,7 +47,6 @@ server {
sub_filter_types *; sub_filter_types *;
} }
# proxy for Nginx proxy Manager # proxy for Nginx proxy Manager
location /w9proxy/ { location /w9proxy/ {
proxy_set_header Host $host; proxy_set_header Host $host;
@ -89,7 +86,6 @@ server {
sub_filter_once off; sub_filter_once off;
} }
# proxy for Gitea # proxy for Gitea
location /w9git/ { location /w9git/ {
proxy_pass http://websoft9-git:3000/; proxy_pass http://websoft9-git:3000/;
@ -106,7 +102,6 @@ server {
} }
} }
location /apidocs/static { location /apidocs/static {
proxy_pass http://websoft9-apphub:8080/static; proxy_pass http://websoft9-apphub:8080/static;
} }
@ -121,7 +116,6 @@ server {
sub_filter 'spec-url="/' 'spec-url="/apidocs/openapi.json'; sub_filter 'spec-url="/' 'spec-url="/apidocs/openapi.json';
} }
# Custom # Custom
include /data/nginx/custom/server_proxy[.]conf; include /data/nginx/custom/server_proxy[.]conf;
} }