修改
This commit is contained in:
@@ -1069,6 +1069,7 @@ services:
|
|||||||
networks:
|
networks:
|
||||||
- ssrf_proxy_network
|
- ssrf_proxy_network
|
||||||
- default
|
- default
|
||||||
|
- urban-lifeline
|
||||||
|
|
||||||
# The Weaviate vector store.
|
# The Weaviate vector store.
|
||||||
weaviate:
|
weaviate:
|
||||||
@@ -1542,7 +1543,9 @@ networks:
|
|||||||
opensearch-net:
|
opensearch-net:
|
||||||
driver: bridge
|
driver: bridge
|
||||||
internal: true
|
internal: true
|
||||||
|
urban-lifeline: # 添加外部网络引用
|
||||||
|
external: true
|
||||||
|
name: urban-lifeline
|
||||||
volumes:
|
volumes:
|
||||||
oradata:
|
oradata:
|
||||||
dify_es01_data:
|
dify_es01_data:
|
||||||
|
|||||||
@@ -84,6 +84,19 @@ server {
|
|||||||
proxy_set_header X-Real-IP $remote_addr;
|
proxy_set_header X-Real-IP $remote_addr;
|
||||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||||
proxy_set_header X-Forwarded-Proto $scheme;
|
proxy_set_header X-Forwarded-Proto $scheme;
|
||||||
|
|
||||||
|
# SPA fallback - 404时返回index.html让Vue Router处理
|
||||||
|
proxy_intercept_errors on;
|
||||||
|
error_page 404 = @platform_fallback;
|
||||||
|
}
|
||||||
|
|
||||||
|
location @platform_fallback {
|
||||||
|
proxy_pass http://platform/index.html;
|
||||||
|
proxy_http_version 1.1;
|
||||||
|
proxy_set_header Host $host;
|
||||||
|
proxy_set_header X-Real-IP $remote_addr;
|
||||||
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||||
|
proxy_set_header X-Forwarded-Proto $scheme;
|
||||||
}
|
}
|
||||||
|
|
||||||
# Workcase 工单系统 PC端
|
# Workcase 工单系统 PC端
|
||||||
@@ -94,6 +107,19 @@ server {
|
|||||||
proxy_set_header X-Real-IP $remote_addr;
|
proxy_set_header X-Real-IP $remote_addr;
|
||||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||||
proxy_set_header X-Forwarded-Proto $scheme;
|
proxy_set_header X-Forwarded-Proto $scheme;
|
||||||
|
|
||||||
|
# SPA fallback - 404时返回index.html让Vue Router处理
|
||||||
|
proxy_intercept_errors on;
|
||||||
|
error_page 404 = @workcase_fallback;
|
||||||
|
}
|
||||||
|
|
||||||
|
location @workcase_fallback {
|
||||||
|
proxy_pass http://workcase-web/index.html;
|
||||||
|
proxy_http_version 1.1;
|
||||||
|
proxy_set_header Host $host;
|
||||||
|
proxy_set_header X-Real-IP $remote_addr;
|
||||||
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||||
|
proxy_set_header X-Forwarded-Proto $scheme;
|
||||||
}
|
}
|
||||||
|
|
||||||
# Bidding 招标系统
|
# Bidding 招标系统
|
||||||
|
|||||||
@@ -27,6 +27,14 @@ spring:
|
|||||||
database: ${REDIS_DATABASE:0}
|
database: ${REDIS_DATABASE:0}
|
||||||
password: ${REDIS_PASSWORD:}
|
password: ${REDIS_PASSWORD:}
|
||||||
|
|
||||||
|
management:
|
||||||
|
endpoints:
|
||||||
|
web:
|
||||||
|
exposure:
|
||||||
|
include: health,info
|
||||||
|
endpoint:
|
||||||
|
health:
|
||||||
|
show-details: always
|
||||||
# ================== Security AES ==================
|
# ================== Security AES ==================
|
||||||
security:
|
security:
|
||||||
aes:
|
aes:
|
||||||
|
|||||||
@@ -1,57 +0,0 @@
|
|||||||
# ================================================
|
|
||||||
# 前端应用 Nginx 配置(单页应用)
|
|
||||||
# ================================================
|
|
||||||
|
|
||||||
user nginx;
|
|
||||||
worker_processes auto;
|
|
||||||
error_log /var/log/nginx/error.log warn;
|
|
||||||
pid /var/run/nginx.pid;
|
|
||||||
|
|
||||||
events {
|
|
||||||
worker_connections 1024;
|
|
||||||
}
|
|
||||||
|
|
||||||
http {
|
|
||||||
include /etc/nginx/mime.types;
|
|
||||||
default_type application/octet-stream;
|
|
||||||
|
|
||||||
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
|
|
||||||
'$status $body_bytes_sent "$http_referer" '
|
|
||||||
'"$http_user_agent"';
|
|
||||||
|
|
||||||
access_log /var/log/nginx/access.log main;
|
|
||||||
|
|
||||||
sendfile on;
|
|
||||||
tcp_nopush on;
|
|
||||||
keepalive_timeout 65;
|
|
||||||
|
|
||||||
# Gzip 压缩
|
|
||||||
gzip on;
|
|
||||||
gzip_vary on;
|
|
||||||
gzip_comp_level 6;
|
|
||||||
gzip_types text/plain text/css text/xml application/json application/javascript
|
|
||||||
application/xml application/xml+rss text/javascript;
|
|
||||||
|
|
||||||
server {
|
|
||||||
listen 80;
|
|
||||||
server_name localhost;
|
|
||||||
root /usr/share/nginx/html;
|
|
||||||
index index.html;
|
|
||||||
|
|
||||||
# SPA 路由支持
|
|
||||||
location / {
|
|
||||||
try_files $uri $uri/ /index.html;
|
|
||||||
}
|
|
||||||
|
|
||||||
# 静态资源缓存
|
|
||||||
location ~* \.(js|css|png|jpg|jpeg|gif|ico|svg|woff|woff2|ttf|eot)$ {
|
|
||||||
expires 7d;
|
|
||||||
add_header Cache-Control "public, immutable";
|
|
||||||
}
|
|
||||||
|
|
||||||
# 禁止访问隐藏文件
|
|
||||||
location ~ /\. {
|
|
||||||
deny all;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -141,8 +141,8 @@ start_web() {
|
|||||||
|
|
||||||
log_info "启动 $web (端口: $port)..."
|
log_info "启动 $web (端口: $port)..."
|
||||||
|
|
||||||
# 使用 serve 启动静态服务
|
# 使用 serve 启动静态服务,--single 确保SPA路由正确处理
|
||||||
nohup serve -s "$site_dir" -l "$port" > "$log_file" 2>&1 &
|
nohup serve -s "$site_dir" -l "$port" --single > "$log_file" 2>&1 &
|
||||||
local pid=$!
|
local pid=$!
|
||||||
echo $pid > "$pid_file"
|
echo $pid > "$pid_file"
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user