admin-webpc/builds/nginx.conf

30 lines
690 B
Nginx Configuration File
Raw Normal View History

2025-02-03 23:58:33 +08:00
server {
listen 80;
server_name ocr-server-admin.bskies.cc;
client_body_buffer_size 10m;
client_max_body_size 100m;
client_header_buffer_size 1m;
2025-02-04 00:33:51 +08:00
# 处理根路径
2025-02-03 23:58:33 +08:00
location / {
2025-02-04 00:33:51 +08:00
root /etc/nginx/html/ocr-server-admin/;
index index.html;
2025-02-03 23:58:33 +08:00
}
2025-02-04 00:24:21 +08:00
2025-02-04 00:33:51 +08:00
# 处理 /index 路径
location = /index {
root /etc/nginx/html/ocr-server-admin/;
try_files /index.html =404;
2025-02-04 00:27:43 +08:00
}
2025-02-06 12:46:13 +08:00
# 处理 /index 路径
location = /login {
root /etc/nginx/html/ocr-server-admin/;
try_files /index.html =404;
}
2025-02-04 00:27:43 +08:00
2025-02-04 00:33:51 +08:00
# 处理其他静态文件
2025-02-04 00:24:21 +08:00
location ~* \.html$ {
root /etc/nginx/html/ocr-server-admin/;
}
2025-02-03 23:58:33 +08:00
}