chore(etcd-operator): bump etcd-operator to v0.5.4 - #3529
Conversation
Bump the cozystack etcd-operator packages from v0.5.3 to v0.5.4. The release is a controller bug-fix set with no API, RBAC or values changes: - fix(controllers): derive --initial-cluster-state from phase, not from the seed (cozystack/etcd-operator#355) - fix(controllers): stop exempting the bootstrap seed from self-heal (cozystack/etcd-operator#354) - fix(controllers): extend crash-loop self-heal to memory members (cozystack/etcd-operator#352) - fix(controllers): switch the PDB from maxUnavailable to minAvailable (cozystack/etcd-operator#351) Adaptations: - etcd-operator/Chart.yaml: appVersion v0.5.3 -> v0.5.4 (the manager image tag defaults to .Chart.AppVersion, so this reimages the controller). - etcd-operator/Makefile, etcd-operator-crds/Makefile: ETCD_OPERATOR_REF v0.5.3 -> v0.5.4. - etcd-operator-crds/templates/etcdmembers.yaml: re-vendored at v0.5.4 via `make update`; description-only change to the /scale replicas/selector fields tracking the PDB minAvailable fix. etcdclusters/etcdsnapshots unchanged. - templates/rbac.yaml left as-is: manager-role-rules.yaml is byte-identical between v0.5.3 and v0.5.4. Assisted-By: Claude <noreply@anthropic.com> Signed-off-by: Andrey Kolkov <androndo@gmail.com>
|
Caution The consumer version of Gemini Code Assist on GitHub has been sunset. All code review activity has officially ceased. |
📝 WalkthroughWalkthroughThe change updates etcd-operator references and deployment test expectations from Changesetcd-operator update
Estimated code review effort: 1 (Trivial) | ~5 minutes Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@packages/system/etcd-operator/Chart.yaml`:
- Line 6: Update both deployment image assertions in deployment_test.yaml for
the manager image and OPERATOR_IMAGE to expect v0.5.4, matching the Chart.yaml
appVersion.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: 0fc07058-f4f9-4b4e-9c43-28ea1221147e
📒 Files selected for processing (4)
packages/system/etcd-operator-crds/Makefilepackages/system/etcd-operator-crds/templates/etcdmembers.yamlpackages/system/etcd-operator/Chart.yamlpackages/system/etcd-operator/Makefile
myasnikovdaniil
left a comment
There was a problem hiding this comment.
NOT LGTM — one blocker, a two-line fix. Everything else in this bump checks out: I verified the vendoring against upstream rather than taking the description on trust, and it is accurate.
Blocker
B1 — helm unittest fails, so the required Unit & controller tests job will go red. packages/system/etcd-operator/tests/deployment_test.yaml:23 and :28 still assert ghcr.io/cozystack/etcd-operator:v0.5.3. The chart derives the manager image tag from .Chart.AppVersion, so bumping appVersion without those two literals breaks the suite. On this branch:
Tests: 1 failed, 17 passed, 18 total # as-is
Tests: 18 passed, 18 total # after s/v0.5.3/v0.5.4/ on those two lines
That suite's own header says it exists to "pin the contracts that are easy to break on an operator bump", so this is the test doing its job. hack/helm-unit-tests.sh picks the package up because its Makefile has a test: target, and make unit-tests gates the PR.
Worth knowing: CI has not surfaced this yet. Run 30893159574 concluded skipped for every job including plan, and the run before it was cancelled by concurrency, so helm-unittest has not executed on this branch at all. The failure is real but currently invisible; it will appear on the next push.
Verified as accurate
- Upstream
v0.5.4exists (a60dd5667f53) andghcr.io/cozystack/etcd-operator:v0.5.4resolves in GHCR. - All three vendored CRDs are byte-identical to upstream v0.5.4. I replicated the Makefile's
awkhelm.sh/resource-policy: keepstamp against upstreamcharts/etcd-operator/crd-bases/and diffed each file:etcdclusters,etcdmembersandetcdsnapshotsare all clean. Theetcdmemberschange really is description-only, andtemplates/contains exactly the three expected files. charts/etcd-operator/files/manager-role-rules.yamlis byte-identical between v0.5.3 and v0.5.4 (empty diff), so leavingtemplates/rbac.yamluntouched is correct.- The upstream
v0.5.3..v0.5.4delta touches only CODEOWNERS, README, docs,api/v1alpha2doc comments, controllers and tests plus the regeneratedcrd-bases. Novalues.yaml, no chart templates, no new required values, no API shape change — the four cited PRs are exactly the delta. - Neither package has a
generate:target or avalues.schema.json, so "nothing formake generate" holds.
Non-blocking
N1 — the PDB switch is safe on live clusters, and the description should say so. I checked this specifically because setting both minAvailable and maxUnavailable is invalid, so a naive patch would wedge the PDB of every existing cluster on upgrade. Upstream reconcilePDB handles it: it treats a surviving pre-migration maxUnavailable as divergence and explicitly sets MaxUnavailable = nil before writing MinAvailable. This is the one change in the release that rewrites live objects, and it leads the release note, so it is worth a line in the description about the upgrade path.
N2 — three pins still read v0.5.2, and I recommend not bumping them here. packages/core/platform/images/migrations/migrations/50 (ETCD_OPERATOR_IMAGE), packages/core/platform/images/migrations/Dockerfile (ETCD_OPERATOR_VERSION plus both pinned sha256s) and hack/migration-50-etcd-adopt.bats:95 each carry a "keep in sync with packages/system/etcd-operator (Chart appVersion)" comment. They drifted at the v0.5.3 bump (c13a10227), so this PR does not introduce the gap. But v1.6.0 shipped migrations.targetVersion: 54, which makes migration 50 already-run history, and the frozen pin is what keeps that adoption reproducible for a cluster still coming from 1.5 or earlier. The real defect is the comments, which now instruct a sync that would be wrong to perform — worth correcting in a separate PR, because left alone every future bumper stops here and has to work this out again.
N3 — area/uncategorized. scopeToArea in .github/workflows/pr-labeler.yaml maps etcd but not etcd-operator, which is why the scope fell through to the fallback. Adding 'etcd-operator': 'area/database' would settle it for future bumps.
| type: application | ||
| version: 0.0.0 # Placeholder, the actual version will be automatically set during the build process | ||
| appVersion: v0.5.3 | ||
| appVersion: v0.5.4 |
There was a problem hiding this comment.
Blocker. This bump needs packages/system/etcd-operator/tests/deployment_test.yaml:23 and :28 updated to v0.5.4 in the same commit. Both still assert ghcr.io/cozystack/etcd-operator:v0.5.3 — one for containers[0].image, one for the OPERATOR_IMAGE env — and the chart derives the tag from .Chart.AppVersion, so helm unittest fails here and takes make unit-tests with it.
Verified on this branch: 1 failed, 17 passed as-is, 18 passed after changing those two literals. Nothing else in the suite is affected.
(Commenting here because that test file is not part of the diff, so GitHub will not accept an inline comment on it.)
| # by hand from config/rbac/role.yaml at this ref. CRDs live in the sibling | ||
| # etcd-operator-crds package. | ||
| ETCD_OPERATOR_REF ?= v0.5.3 | ||
| ETCD_OPERATOR_REF ?= v0.5.4 |
There was a problem hiding this comment.
Non-blocking, and foldable into this PR since you are already editing these lines: the comment just above points at config/rbac/role.yaml, but upstream has no config/rbac/ directory at all. The rules actually live in charts/etcd-operator/files/manager-role-rules.yaml — the path the PR description cites correctly. Pre-existing, but it is the instruction the next person follows when re-vendoring the ClusterRole.
The manager image tag derives from .Chart.AppVersion, so bumping appVersion to v0.5.4 without updating the two image literals in the deployment unittest broke the suite (helm-unittest gates the PR via `make unit-tests`). Update both asserts (manager container image and the agent OPERATOR_IMAGE env) to ghcr.io/cozystack/etcd-operator:v0.5.4. Suite is green again (18/18). Assisted-By: Claude <noreply@anthropic.com> Signed-off-by: Andrey Kolkov <androndo@gmail.com>
|
myasnikovdaniil thanks for the thorough pass — especially verifying the vendoring and the PDB migration against upstream rather than on trust. B1 (blocker) — fixed in 22c1df8. Both image literals in N1 — done. Added an "Upgrade path" paragraph to the PR description noting that upstream N2 — agreed, leaving the migration-50 pins alone here. The N3 — noted, out of scope for this bump. Adding |
myasnikovdaniil
left a comment
There was a problem hiding this comment.
LGTM. B1 is fixed correctly and I re-verified the whole change at 22c1df8b.
22c1df8b touches exactly the two literals and nothing else (1 file, +2/-2), and the suite is green — 18/18 locally, and the Unit & controller tests job passes in CI. No etcd-operator:v0.5.3 or stale ETCD_OPERATOR_REF survives anywhere in the tree, and the full diff is still the four original files plus the test file, so there is no scope creep.
N1 is addressed, and the new "Upgrade path (PDB switch)" paragraph is accurate — it matches what upstream reconcilePDB actually does at v0.5.4. N2 is correctly left alone.
The earlier verification all still holds: the three vendored CRDs are byte-identical to upstream v0.5.4 with the helm.sh/resource-policy: keep stamp applied, manager-role-rules.yaml is unchanged between v0.5.3 and v0.5.4 so templates/rbac.yaml needs no edit, and the upstream delta contains no values, template or API-shape change.
Two things for whoever merges, neither blocking:
The red Require API owner review for sizeable API changes is not a real failure. Two runs exist at this SHA: the one triggered by pull_request_review (my earlier review submission) was cancelled by concurrency, which surfaces as a failing check run, while the pull_request-triggered run passed. Check runs do not dedupe across workflow runs and the rollup is worst-of, so a cancelled duplicate can sit beside its passing twin. Re-running the cancelled run clears it if the merge gate balks.
E2E was still pending when I approved, so this approval covers the change itself and not the E2E result — worth a glance before merging.
Optional nit left over from N3, whenever this Makefile is next touched: the comment on line 9 and the echo on line 15 both point at config/rbac/role.yaml, which does not exist upstream — the rules live in charts/etcd-operator/files/manager-role-rules.yaml, the path the description cites correctly.
|
Successfully created backport PR for |
What this PR does
Bumps the cozystack etcd-operator packages from v0.5.3 to v0.5.4.
v0.5.4is a controller bug-fix release — no API, RBAC or values changes:--initial-cluster-statefrom phase, not from the seed (cozystack/etcd-operator#355)maxUnavailabletominAvailable(cozystack/etcd-operator#351)Changes in this repo:
packages/system/etcd-operator/Chart.yaml—appVersion: v0.5.3 → v0.5.4. The manager image tag defaults to.Chart.AppVersion(values.yamlkeepstag: ""), so this reimages the controller toghcr.io/cozystack/etcd-operator:v0.5.4.packages/system/etcd-operator/Makefile,packages/system/etcd-operator-crds/Makefile—ETCD_OPERATOR_REF: v0.5.3 → v0.5.4.packages/system/etcd-operator-crds/templates/etcdmembers.yaml— re-vendored at v0.5.4 viamake update. Description-only change to the/scalereplicas/selectorfield docs, tracking the PDBminAvailablefix.etcdclustersandetcdsnapshotsare byte-identical to v0.5.3.templates/rbac.yamlintentionally left as-is:manager-role-rules.yamlis byte-identical between v0.5.3 and v0.5.4.Upgrade path (PDB switch, cozystack/etcd-operator#351). This is the one change that rewrites live objects: the operator moves each EtcdCluster's PodDisruptionBudget from
maxUnavailabletominAvailable. Setting both fields is invalid, but upstreamreconcilePDBhandles the migration — it treats a surviving pre-migrationmaxUnavailableas divergence and explicitly clears it (MaxUnavailable = nil) before writingMinAvailable, so existing clusters are reconciled cleanly on upgrade rather than wedging their PDB.Verified locally:
helm lintandhelm templatepass for both packages; rendered manager image resolves toghcr.io/cozystack/etcd-operator:v0.5.4. Thesepackages/system/*packages have nogenerate:target and novalues.schema.json, so there is nothing formake generateto regenerate.Screenshots
Not applicable — no UI changes.
Downstream repositories
Walked the trigger map in
docs/agents/contributing.mdfile-by-file against the diff:The diff touches only
packages/system/etcd-operator*— nopackages/apps/**orpackages/extra/**add/rename/remove, nopackages/core/platformorinstallervalues, no Talos bump, no asset-name or dev-tooling change → website / ansible-cozystack not reached.The CRD edit is description-only, inside etcd-operator's own
etcd-operator.cozystack.ioCRDs — not the provider's hand-typedPackage/Plan/RestoreJobtypes, and no new managed app → terraform-provider-cozystack not reached.No
hack/change, nopackages/system/<name>-rd/cozyrds/**, noApplicationDefinitionCRD /chartRef.kindenum change, nocozyhr/package.mkcontract change, no telemetry-metric or proxy-label rename → ccp / talm / cozyhr / cozy-proxy / telemetry-server / examples / external-apps-example not reached.No downstream repository is affected by this change
cozystack/website - follow-up:
cozystack/terraform-provider-cozystack - follow-up:
cozystack/ansible-cozystack - follow-up:
cozystack/ccp - follow-up:
cozystack/talm - follow-up:
cozystack/cozyhr - follow-up:
cozystack/cozy-proxy - follow-up:
cozystack/cozystack-telemetry-server - follow-up:
cozystack/external-apps-example - follow-up:
cozystack/examples - follow-up:
Release note
Summary by CodeRabbit