gateway/dynamic.yml

145 lines
3.2 KiB
YAML
Raw Normal View History

2025-08-25 23:25:02 +08:00
http:
routers:
# Sys Auth
sys-auth:
entryPoints: ["sys"]
rule: "PathPrefix(`/auth`)"
service: ids4
middlewares: [strip-auth, cors, ids4-hostfix]
sys-connect:
entryPoints: ["sys"]
rule: "PathPrefix(`/connect`)"
service: ids4
middlewares: [cors, ids4-hostfix]
sys-api:
entryPoints: ["sys"]
rule: "PathPrefix(`/api/sys`)"
service: sys-api
middlewares: [cors, auth-header, strip-api-sys]
sys-ui:
entryPoints: ["sys"]
rule: "PathPrefix(`/`)"
service: sys-ui
middlewares: [cors]
# LMG Auth
lmg-auth:
entryPoints: ["lmg"]
rule: "PathPrefix(`/auth`)"
service: ids4
middlewares: [strip-auth, cors, ids4-hostfix]
lmg-api:
entryPoints: ["lmg"]
rule: "PathPrefix(`/api/lmg`)"
service: lmg-api
middlewares: [cors, auth-header, strip-api-lmg]
lmg-ui:
entryPoints: ["lmg"]
rule: "PathPrefix(`/`)"
service: lmg-ui
middlewares: [cors]
# Healthy Auth
healthy-auth:
entryPoints: ["healthy"]
rule: "PathPrefix(`/auth`)"
service: ids4
middlewares: [strip-auth, cors, ids4-hostfix]
healthy-api:
entryPoints: ["healthy"]
rule: "PathPrefix(`/api/healthy`)"
service: healthy-api
middlewares: [cors, auth-header, strip-api-healthy]
healthy-ui:
entryPoints: ["healthy"]
rule: "PathPrefix(`/`)"
service: healthy-ui
middlewares: [cors]
services:
ids4:
loadBalancer:
servers:
- url: "https://sys-api:8001"
serversTransport: ids4-transport
sys-api:
loadBalancer:
servers:
- url: "https://sys-api:8001"
serversTransport: ids4-transport
sys-ui:
loadBalancer:
servers:
- url: "http://sys-ui:80"
lmg-api:
loadBalancer:
servers:
- url: "https://lmg-api:19904"
serversTransport: ids4-transport
lmg-ui:
loadBalancer:
servers:
- url: "http://lmg-ui:80"
healthy-api:
loadBalancer:
servers:
- url: "https://healthy-api:19906"
serversTransport: ids4-transport
healthy-ui:
loadBalancer:
servers:
- url: "http://healthy-ui:80"
serversTransports:
ids4-transport:
insecureSkipVerify: true
middlewares:
cors:
headers:
accessControlAllowOriginList: ["*"]
accessControlAllowMethods: ["GET", "POST", "PUT", "DELETE", "OPTIONS"]
accessControlAllowHeaders: ["Authorization", "Content-Type"]
accessControlAllowCredentials: true
addVaryHeader: true
strip-auth:
stripPrefix:
prefixes: ["/auth"]
strip-api-sys:
stripPrefix:
prefixes: ["/api/sys"]
strip-api-lmg:
stripPrefix:
prefixes: ["/api/lmg"]
strip-api-healthy:
stripPrefix:
prefixes: ["/api/healthy"]
ids4-hostfix:
headers:
customRequestHeaders:
Host: "106.52.199.114:8001"
X-Forwarded-Host: "106.52.199.114:8001"
X-Forwarded-Proto: "https"
auth-header:
headers:
customRequestHeaders:
Authorization: "{header:Authorization}"