#---ssl 301 转跳 ---#
if ($server_port = 80){
rewrite ^(/2.php)$ http://www.eisc.cn$1 permanent;
}
#--- 目录301 转跳 ---#
设置 301 转跳,
location /ccb/ {
return 301 http://work.eisc.cn;
proxy_pass http://eisc.cn/cs;
index index.html index.htm;
}
# 设置 302 重定向
location /ccb/ {
rewrite /ccb/activity(.*)$ https://www.baidu.com break;
proxy_pass http://192.168.118.14/;
index index.html index.htm;
}
#---------------------------- nginx 转发 反向代理 -----------------------------#
# nginx 子站点tcp转发
server{
listen 80 ;
listen 443;
server_name kbash.cn www.kbash.cn;
location / {
proxy_pass http://82.157.148.144:80;
index index.php index.html;
}
}
#---------------------------------------------------------------------#