guanghu-ice-heart/server-tools/zhulan-remote-cell/deploy/guanghulab-zhulan.nginx.conf

41 lines
1.5 KiB
Text

# BS-GZ-006 only: domain/TLS/reverse proxy. UI and all real services remain on BS-SG-003.
# The local upstream port must be supplied by a dedicated restricted tunnel.
location = /zhulan {
return 308 /zhulan/;
}
# Runtime-only verification is reachable from the BS-SG-003 loopback executor,
# never through the Guangzhou public projection.
location ^~ /zhulan/api/v1/runtime/ {
return 404;
}
location ^~ /zhulan/ {
proxy_pass http://127.0.0.1:17631/;
proxy_http_version 1.1;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-Host $host;
proxy_set_header X-Forwarded-Proto https;
proxy_set_header X-Forwarded-Prefix /zhulan;
# Do not inherit a client-supplied X-Forwarded-For chain. The runtime uses
# this value for per-source rate limits.
proxy_set_header X-Forwarded-For $remote_addr;
proxy_connect_timeout 5s;
proxy_read_timeout 30s;
proxy_send_timeout 30s;
client_max_body_size 1m;
}
# RFC 8414 path-aware discovery aliases for issuer
# https://guanghulab.com/zhulan. These are metadata projections only.
location = /.well-known/oauth-authorization-server/zhulan {
proxy_pass http://127.0.0.1:17631/.well-known/oauth-authorization-server;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-Proto https;
}
location = /.well-known/oauth-protected-resource/zhulan/mcp {
proxy_pass http://127.0.0.1:17631/.well-known/oauth-protected-resource;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-Proto https;
}