直接 vim conf/nginx.conf文件
server {
listen 8081;
server_name localhost;
charset koi8-r;
access_log logs/host.access.log main;
location / {
root /home/www;
index index.html index.htm;
try_files $uri $uri/ /index.html;
}
然后esc 退出 wq! 进行保存
关闭 …./nginx -s stop
重启 …/nginx
Original: https://www.cnblogs.com/angelasp/p/13026377.html
Author: Angelasp
Title: vue部署在nginx后刷新404,nginx.conf一行代码解决掉
原创文章受到原创版权保护。转载请注明出处:https://www.johngo689.com/612421/
转载文章受原作者版权保护。转载请注明原作者出处!