feat(infra-gitops): add suspend logic for infra-gitops-post based on environment variables
这个提交包含在:
+6
-1
@@ -48,11 +48,14 @@ Kustomization 间通过 `dependsOn` + `wait: true` 串行等待,避免顺序
|
||||
|
||||
## 部署后手工步骤(infra-gitops-post)
|
||||
|
||||
`infra-gitops-post` 默认 `suspend: true`,因为它依赖两类只能在 Gitea 启动后获取的凭据:
|
||||
`infra-gitops-post` 通过父级 Kustomization 的 `spec.suspend: ${INFRA_GITOPS_POST_SUSPEND:=true}`
|
||||
默认暂停,因为它依赖两类只能在 Gitea 启动后获取的凭据:
|
||||
|
||||
1. **Flux Operator Web 的 OIDC 客户端**
|
||||
2. **Gitea Actions Runner Token**
|
||||
|
||||
`flux-env` Secret 中设置 `INFRA_GITOPS_POST_SUSPEND=true|false`,从而决定 post 层是否自动放行。
|
||||
|
||||
步骤:
|
||||
|
||||
1. 浏览器访问 `https://git.dev.cm`,首个注册账号自动成为 admin。
|
||||
@@ -68,6 +71,8 @@ Kustomization 间通过 `dependsOn` + `wait: true` 串行等待,避免顺序
|
||||
FLUX_WEB_OIDC_CLIENT_ID=<step 2 client id>
|
||||
FLUX_WEB_OIDC_CLIENT_SECRET=<step 2 client secret>
|
||||
GITEA_ACTIONS_TOKEN=<step 3 token>
|
||||
|
||||
INFRA_GITOPS_POST_SUSPEND=false
|
||||
```
|
||||
|
||||
5. 重新注入 `flux-env` Secret 并协调:
|
||||
|
||||
在新议题中引用
屏蔽一个用户