Files
ai_site/gateway/apisix/apisix.yaml
2026-07-31 10:19:22 +08:00

39 lines
822 B
YAML

routes:
- id: platform-api
uri: /api/v1/*
name: platform-api
methods: ["GET", "POST", "PUT", "PATCH", "DELETE", "OPTIONS"]
upstream:
type: roundrobin
nodes:
"host.docker.internal:8888": 1
plugins:
cors:
allow_origins: "**"
allow_methods: "**"
allow_headers: "**"
limit-req:
rate: 50
burst: 30
key_type: var
key: remote_addr
rejected_code: 429
- id: ai-service
uri: /ai/*
name: ai-service
methods: ["GET", "POST", "OPTIONS"]
upstream:
type: roundrobin
nodes:
"host.docker.internal:8001": 1
plugins:
cors:
allow_origins: "**"
allow_methods: "**"
allow_headers: "**"
proxy-rewrite:
regex_uri: ["^/ai/(.*)", "/$1"]
#END