nginx 配置支持URL HTML5 History 模式 与 设置代理

拾人牙慧:https://segmentfault.com/q/1010000007140360

 

nginx 配置支持URL HTML5 History 模式

location / {
   try_files $uri /index.html;
}

location ^~ /api/ {
  proxy_pass  http://192.168.8.184:8080/api/;
}

 

posted @ 2018-09-13 15:26  贝尔塔猫  阅读(1561)  评论(0编辑  收藏  举报