refactor(admin): 移除待定排名页面并更新配置
- 删除待定排名页面及相关路由配置 - 更新环境变量配置,调整API地址和主页路由 - 添加vite-auto-deploy依赖和nginx配置文件 - 更新组件类型定义,移除未使用的组件 - 调整页面标题和图片资源
This commit is contained in:
34
apps/admin/nginx.conf
Normal file
34
apps/admin/nginx.conf
Normal file
@ -0,0 +1,34 @@
|
||||
server {
|
||||
listen 80;
|
||||
server_name localhost;
|
||||
|
||||
# 设置根目录为打包后的 dist 文件夹
|
||||
root /usr/share/nginx/html;
|
||||
index index.html;
|
||||
|
||||
# 开启 gzip 压缩
|
||||
gzip on;
|
||||
gzip_min_length 1k;
|
||||
gzip_comp_level 6;
|
||||
gzip_types text/plain application/javascript application/x-javascript text/css application/xml text/javascript application/x-httpd-php image/jpeg image/gif image/png;
|
||||
gzip_vary on;
|
||||
gzip_disable "MSIE [1-6]\.";
|
||||
|
||||
# 核心配置:处理 SPA 路由 fallback
|
||||
location / {
|
||||
try_files $uri $uri/ /index.html;
|
||||
}
|
||||
|
||||
# 静态资源缓存配置(可选)
|
||||
location ~* \.(js|css|png|jpg|jpeg|gif|ico|svg)$ {
|
||||
expires 30d;
|
||||
add_header Cache-Control "public, no-transform";
|
||||
}
|
||||
|
||||
# 代理接口配置(如果需要)
|
||||
# location /api/ {
|
||||
# proxy_pass http://backend-api.com/;
|
||||
# proxy_set_header Host $host;
|
||||
# proxy_set_header X-Real-IP $remote_addr;
|
||||
# }
|
||||
}
|
||||
Reference in New Issue
Block a user