- FastAPI 백엔드 + MongoDB + Redis 구성 - React + Vite + TypeScript + shadcn/ui 프론트엔드 - Apache APISIX API Gateway 통합 - Docker Compose 기반 개발 환경 - 3단계 권한 체계 (System Admin, Group Admin, User) - 동적 테마 지원 - 환경별 설정 (dev/vei/prod) 🤖 Generated with Claude Code Co-Authored-By: Claude <noreply@anthropic.com>
119 lines
2.5 KiB
YAML
119 lines
2.5 KiB
YAML
routes:
|
|
- uri: /api/v1/auth/*
|
|
name: auth-service
|
|
upstream:
|
|
type: roundrobin
|
|
nodes:
|
|
backend:8000: 1
|
|
plugins:
|
|
cors:
|
|
allow_origins: "*"
|
|
allow_methods: "GET,POST,PUT,DELETE,OPTIONS"
|
|
allow_headers: "*"
|
|
expose_headers: "*"
|
|
limit-req:
|
|
rate: 10
|
|
burst: 20
|
|
rejected_code: 429
|
|
request-id:
|
|
header_name: "X-Request-Id"
|
|
include_in_response: true
|
|
|
|
- uri: /api/v1/users/*
|
|
name: user-service
|
|
upstream:
|
|
type: roundrobin
|
|
nodes:
|
|
backend:8000: 1
|
|
plugins:
|
|
jwt-auth:
|
|
key: "user-key"
|
|
secret: "my-secret-key"
|
|
cors:
|
|
allow_origins: "*"
|
|
allow_methods: "GET,POST,PUT,DELETE,OPTIONS"
|
|
allow_headers: "*"
|
|
expose_headers: "*"
|
|
limit-req:
|
|
rate: 100
|
|
burst: 50
|
|
rejected_code: 429
|
|
|
|
- uri: /api/v1/applications/*
|
|
name: application-service
|
|
upstream:
|
|
type: roundrobin
|
|
nodes:
|
|
backend:8000: 1
|
|
plugins:
|
|
jwt-auth:
|
|
key: "user-key"
|
|
secret: "my-secret-key"
|
|
cors:
|
|
allow_origins: "*"
|
|
allow_methods: "GET,POST,PUT,DELETE,OPTIONS"
|
|
allow_headers: "*"
|
|
expose_headers: "*"
|
|
limit-req:
|
|
rate: 50
|
|
burst: 25
|
|
rejected_code: 429
|
|
|
|
- uri: /api/v1/admin/*
|
|
name: admin-service
|
|
upstream:
|
|
type: roundrobin
|
|
nodes:
|
|
backend:8000: 1
|
|
plugins:
|
|
jwt-auth:
|
|
key: "admin-key"
|
|
secret: "admin-secret-key"
|
|
ip-restriction:
|
|
whitelist:
|
|
- 10.0.0.0/8
|
|
- 172.16.0.0/12
|
|
- 192.168.0.0/16
|
|
cors:
|
|
allow_origins: "*"
|
|
allow_methods: "GET,POST,PUT,DELETE,OPTIONS"
|
|
allow_headers: "*"
|
|
expose_headers: "*"
|
|
limit-req:
|
|
rate: 200
|
|
burst: 100
|
|
rejected_code: 429
|
|
|
|
- uri: /health
|
|
name: health-check
|
|
upstream:
|
|
type: roundrobin
|
|
nodes:
|
|
backend:8000: 1
|
|
plugins:
|
|
limit-req:
|
|
rate: 1000
|
|
burst: 500
|
|
|
|
- uri: /*
|
|
name: frontend
|
|
upstream:
|
|
type: roundrobin
|
|
nodes:
|
|
frontend:80: 1
|
|
plugins:
|
|
proxy-cache:
|
|
cache_zone:
|
|
name: disk_cache_one
|
|
memory_size: 50m
|
|
disk_size: 1G
|
|
disk_path: "/tmp/disk_cache"
|
|
cache_method:
|
|
- GET
|
|
- HEAD
|
|
cache_http_status:
|
|
- 200
|
|
- 301
|
|
- 404
|
|
cache_ttl: 300
|
|
hide_cache_headers: true |