这是反向代理1的配置
#PROXY-START/xxl-job-admin/
location ^~ /xxl-job-admin/
{
proxy_pass http://localhost:9100/xxl-job-admin/;
proxy_set_header Host localhost;
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 $connection_upgrade;
proxy_http_version 1.1;
# proxy_hide_header Upgrade;
add_header X-Cache $upstream_cache_status;
#Set Nginx Cache
set $static_file0oAJ474Q 0;
if ( $uri ~* "\.(gif|png|jpg|css|js|woff|woff2)$" )
{
set $static_file0oAJ474Q 1;
expires 1m;
}
if ( $static_file0oAJ474Q = 0 )
{
add_header Cache-Control no-cache;
}
}
#PROXY-END/xxl-job-admin/
这是反向代理2的配置
#PROXY-START/admin/
location ^~ /admin/
{
proxy_pass http://localhost:9090/admin/;
proxy_set_header Host localhost;
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 $connection_upgrade;
proxy_http_version 1.1;
# proxy_hide_header Upgrade;
add_header X-Cache $upstream_cache_status;
#Set Nginx Cache
set $static_fileXXRysTyt 0;
if ( $uri ~* "\.(gif|png|jpg|css|js|woff|woff2)$" )
{
set $static_fileXXRysTyt 1;
expires 1m;
}
if ( $static_fileXXRysTyt = 0 )
{
add_header Cache-Control no-cache;
}
}
#PROXY-END/admin/ |