diff --git a/infrastructure/sandbox-cluster/README.md b/infrastructure/sandbox-cluster/README.md index e0bfeaa..df2b174 100644 --- a/infrastructure/sandbox-cluster/README.md +++ b/infrastructure/sandbox-cluster/README.md @@ -93,6 +93,13 @@ ansible-playbook site.yml ansible-playbook k3s.yml ``` +只 reconcile Flux controllers 与 root sync manifest(不触碰 LXC、PostgreSQL 或 +K3s lifecycle): + +```bash +ansible-playbook flux.yml +``` + K3s 外部 datastore URI 由运行时 `SANDBOX_K3S_DB_PASSWORD` 生成,密码在 URI 中 进行 URL 编码,最终仅持久化于节点 root 可读的 `/etc/rancher/k3s/config.yaml` (mode `0600`)。首节点生成的 K3s join token 仅在同一次 Ansible run 内传给第二节点; diff --git a/infrastructure/sandbox-cluster/ansible/flux.yml b/infrastructure/sandbox-cluster/ansible/flux.yml new file mode 100644 index 0000000..8e5d993 --- /dev/null +++ b/infrastructure/sandbox-cluster/ansible/flux.yml @@ -0,0 +1,6 @@ +--- +- name: Reconcile Flux controllers and root sync + hosts: sandbox1 + gather_facts: false + roles: + - sandbox_flux diff --git a/platform/sandbox-external-secrets/README.md b/platform/sandbox-external-secrets/README.md index 027972d..484968c 100644 --- a/platform/sandbox-external-secrets/README.md +++ b/platform/sandbox-external-secrets/README.md @@ -13,6 +13,9 @@ homelab 集群的 ESO Pod、ServiceAccount 或 Kubernetes auth backend。 值未输出或落盘; - sandbox ESO operator、`ClusterSecretStore/openbao` 与 OpenSandbox `ExternalSecret` 由 Flux 管理; +- 线上 `ClusterSecretStore/openbao` 为 `Valid/Ready`,`ExternalSecret/opensandbox-api-key` + 为 `SecretSynced/Ready`; +- OpenSandbox 已切换到 API key:无 key 请求返回 `401`,正确 key 请求返回 `200`; - homelab runner 对同一 key 的投影不在本目录,留给 runner 项目管理。 OpenBao 的 `auth/kubernetes-sandbox`、对应 role、policy、sandbox API 地址与公开 CA diff --git a/platform/sandbox-opensandbox/README.md b/platform/sandbox-opensandbox/README.md index d04e982..beb978f 100644 --- a/platform/sandbox-opensandbox/README.md +++ b/platform/sandbox-opensandbox/README.md @@ -27,6 +27,8 @@ runner 项目后续声明,本目录不预制。 仓库与 Helm values 均不保存 API key。OpenSandbox 不支持更丰富的原生 workload authentication;runner 后续读取同一 Bao 路径并在请求头中使用 API key。 +`opensandbox-values` 带 Flux watch label,values 变化会立即触发 Helm reconcile,不依赖 +30 分钟的 HelmRelease interval。 ## 验收 diff --git a/platform/sandbox-opensandbox/values.yaml b/platform/sandbox-opensandbox/values.yaml index 4653436..21d20e8 100644 --- a/platform/sandbox-opensandbox/values.yaml +++ b/platform/sandbox-opensandbox/values.yaml @@ -4,6 +4,8 @@ kind: ConfigMap metadata: name: opensandbox-values namespace: opensandbox-system + labels: + reconcile.fluxcd.io/watch: Enabled data: values.yaml: | opensandbox-controller: