main:新增健康检查支持和服务优化
- 在 Worker 中引入轻量级 HTTP 服务器,支持健康检查和就绪检查端点。 - 在 Kubernetes 和 Docker 配置中新增健康检查探针,提升服务稳定性。 - 更新依赖,引入 `aiohttp` 用于健康检查服务。 - 优化部署配置,调整 Redis 主机配置和镜像地址以适配新环境。
This commit is contained in:
@@ -5,11 +5,11 @@ name: functional-scaffold
|
||||
access: default
|
||||
|
||||
vars:
|
||||
region: cn-hangzhou
|
||||
image: registry.cn-hangzhou.aliyuncs.com/your-namespace/functional-scaffold:latest
|
||||
redis_host: r-xxxxx.redis.rds.aliyuncs.com
|
||||
region: cn-beijing
|
||||
image: crpi-om2xd9y8cmaizszf-vpc.cn-beijing.personal.cr.aliyuncs.com/test-namespace-gu/fc-test:test-v1
|
||||
redis_host: 172.17.133.51
|
||||
redis_port: "6379"
|
||||
redis_password: "your-password"
|
||||
redis_password: "roog-pass-redis"
|
||||
|
||||
resources:
|
||||
# API 服务函数
|
||||
@@ -78,6 +78,13 @@ resources:
|
||||
port: 8000
|
||||
command:
|
||||
- /app/entrypoint.sh
|
||||
healthCheckConfig:
|
||||
httpGetUrl: /healthz
|
||||
initialDelaySeconds: 5
|
||||
periodSeconds: 10
|
||||
timeoutSeconds: 3
|
||||
failureThreshold: 3
|
||||
successThreshold: 1
|
||||
environmentVariables:
|
||||
APP_ENV: production
|
||||
LOG_LEVEL: INFO
|
||||
|
||||
Reference in New Issue
Block a user