https 协议

This commit is contained in:
yidl 2025-06-28 23:03:36 +08:00
parent d8dd567f25
commit 7787668092
1 changed files with 5 additions and 2 deletions

View File

@ -34,7 +34,6 @@ http {
# 认证中心 (IdentityServer4) # 认证中心 (IdentityServer4)
upstream auth_server { upstream auth_server {
server sys-api:19902; server sys-api:19902;
proxy_ssl_verify off; # 关闭证书验证
} }
# Sys 系统 API # Sys 系统 API
@ -94,18 +93,22 @@ http {
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;
proxy_ssl_verify off; # 关闭证书验证
} }
# 1. 认证中心 (IdentityServer4) 路由 # 1. 认证中心 (IdentityServer4) 路由
# 匹配所有认证相关的路径 # 匹配所有认证相关的路径
location ~ ^/(connect|Account)/ { location ~ ^/(connect|Account)/ {
proxy_pass https://auth_server; proxy_pass https://auth_server;
proxy_ssl_verify off; # 关闭证书验证
} }
# 2. Sys API 路由 # 2. Sys API 路由
location /api/sys/ { location /api/sys/ {
# 将 /api/sys/path -> http://sys_api/api/sys/path # 将 /api/sys/path -> http://sys_api/api/sys/path
proxy_pass http://sys_api; proxy_pass https://sys_api;
proxy_ssl_verify off; # 关闭证书验证
} }
# 3. Lmg API 路由 # 3. Lmg API 路由