ng一个域名配置两个页面


server {
listen 80;
server_name localhost;
location / {
root /opt/;
# try_files $uri $uri/ /index.html;
# index index.html index.htm;
}

location /admin {
alias /opt/aiqs-adminnew/;
try_files $uri $uri/ /index.html;
index index.html index.htm;
# rewrite ^/.*/$ / last; # Redirect everything to / (ex index.html) and let the JS router take care of the rest
# rewrite ^([^.]*[^/])$ $1/ permanent; # Force trailing slash
}

location /app {
alias /opt/aiqs-h5old/;
try_files $uri $uri/ /index.html;
index index.html index.htm;
# rewrite ^/.*/$ / last; # Redirect everything to / (ex index.html) and let the JS router take care of the rest
# rewrite ^([^.]*[^/])$ $1/ permanent; # Force trailing slash
}

#转发 

location /client {
proxy_pass http://******.****.****.com/;
}

 

同时页面更改 homepage:"."

增加 # 寻找所有js css

posted @ 2020-08-07 09:11  老小包的博客  阅读(359)  评论(0编辑  收藏  举报