feat: 添加kubernetes部署

This commit is contained in:
2025-12-24 11:49:34 +08:00
parent b97705532e
commit 7f160a8d2a
11 changed files with 958 additions and 2 deletions

32
test/k8s/configmap.yaml Normal file
View File

@@ -0,0 +1,32 @@
# ConfigMap for ez-api stack configuration
apiVersion: v1
kind: ConfigMap
metadata:
name: ez-api-config
namespace: ez-api-test-dev
labels:
app.kubernetes.io/name: ez-api-test-dev
app.kubernetes.io/component: config
data:
# PostgreSQL configuration
POSTGRES_DB: "ezapi"
LOG_POSTGRES_DB: "ezapi_logs"
# ez-api configuration
EZ_API_PORT: "8080"
EZ_CORS_ALLOW_ORIGINS: "*"
EZ_LOG_RETENTION_DAYS: "30"
EZ_LOG_MAX_RECORDS: "1000000"
EZ_LOG_PARTITIONING: "off"
# Balancer configuration
EZ_BALANCER_PORT: "8081"
EZ_REDIS_DB: "0"
EZ_BALANCER_LOG_SINK_ENABLED: "false"
EZ_BALANCER_LOG_SINK_BASE_URL: "http://ez-api:8080"
EZ_BALANCER_LOG_SINK_TIMEOUT_SECONDS: "3"
EZ_BALANCER_STATS_FLUSH_ENABLED: "false"
EZ_BALANCER_STATS_FLUSH_BASE_URL: "http://ez-api:8080"
EZ_BALANCER_STATS_FLUSH_INTERVAL_SECONDS: "300"
EZ_BALANCER_STATS_FLUSH_BATCH_SIZE: "200"
EZ_BALANCER_STATS_FLUSH_TIMEOUT_SECONDS: "5"