完善项目
This commit is contained in:
@@ -19,13 +19,18 @@ server {
|
||||
access_log off;
|
||||
}
|
||||
|
||||
# 处理Vue Router的history模式
|
||||
location / {
|
||||
try_files $uri $uri/ /index.html;
|
||||
# 处理Vue Router的history模式 - 支持/farm/路径
|
||||
location /farm/ {
|
||||
try_files $uri $uri/ /farm/index.html;
|
||||
add_header Cache-Control "no-cache, no-store, must-revalidate";
|
||||
add_header Pragma "no-cache";
|
||||
add_header Expires "0";
|
||||
}
|
||||
|
||||
# 根路径重定向到/farm/
|
||||
location = / {
|
||||
return 301 /farm/;
|
||||
}
|
||||
|
||||
# API代理到后端服务
|
||||
location /api/ {
|
||||
|
||||
Reference in New Issue
Block a user