首页 > 其他 > 详细

nginx配置vue项目

时间:2021-08-13 17:11:48      阅读:19      评论:0      收藏:0      [点我收藏+]
server {
        # 端口号
        listen       3309;
        # IP
        server_name  192.168.1.3;

        location / {
                # 执行目录
                root   /var/www/vue-app-base/dist/;
                index index.html;
                # index  index.html index.htm;
                # vue支持路由跳转
                try_files  $uri $uri/ /index.html;
        }

        # 反向代理 解决跨域问题
        location ^~ /riegl/ {
                proxy_pass http://192.168.1.3:8080;
        }

        location ^~ /APX/ {
                proxy_pass http://192.168.1.3:8080;
        }

        location ^~ /set/ {
                proxy_pass http://192.168.1.3:8080;
        }
}

nginx配置vue项目

原文:https://www.cnblogs.com/zhangxuechao/p/15137458.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!