Skip to content

[Backport release-1.6] feat(clickhouse): add configurable version parameter - #4054

Merged
myasnikovdaniil merged 2 commits into
release-1.6from
backport-3476-to-release-1.6
Sep 3, 2026
Merged

myasnikovdaniil merged 2 commits into
release-1.6from
backport-3476-to-release-1.6

Conversation

@github-actions

@github-actions github-actions Bot commented Sep 3, 2026

Copy link
Copy Markdown

Description

Backport of #3476 to release-1.6.

@github-actions

github-actions Bot commented Sep 3, 2026

Copy link
Copy Markdown
Author

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin backport-3476-to-release-1.6
git worktree add --checkout .worktree/backport-3476-to-release-1.6 backport-3476-to-release-1.6
cd .worktree/backport-3476-to-release-1.6
git reset --hard HEAD^
git cherry-pick -x 3c78c0be569cd4e5a4d53f74c6d64f96494349b8 e707475f960831d47883c354d8386fa0db835bbb
git push --force-with-lease

Add a `version` value (v25.8, v25.3, v24.9; default v24.9) to the
ClickHouse chart, backed by files/versions.yaml and resolved by
templates/_versions.tpl for both the ClickHouse server and Keeper
images, so the Cozystack API returns the engine version (spec.version)
like the other managed-DB charts. Default v24.9 -> 24.9.2.42 keeps
existing installations byte-for-byte identical.

The maintainer-run hack/update-versions.sh generator intersects the
server/keeper Docker Hub tags byte-collated (LC_ALL=C) so comm keeps
tags across the X.9 -> X.10 boundary; freezes the default major to the
tag it already ships (read from versions.yaml, so the freeze follows the
default); errors on a dropped default or an unresolvable major; writes
atomically; and runs on stock macOS bash 3.2 / BSD. Covered by
hack/clickhouse-update-versions_test.bats (10 cases) and the
tests/version_test.yaml helm-unittest suite.

Refs: #1246
Signed-off-by: Alexey Artamonov <[email protected]>
(cherry picked from commit 3c78c0b)
Signed-off-by: Myasnikov Daniil <[email protected]>
Assisted-By: LLM
Address review of the version generator (hack/update-versions.sh):

- Fetch tags with `skopeo list-tags` (registry v2 /tags/list) instead of
  the Docker Hub v2 API, whose anonymous pagination caps at 1000 entries
  and then returns an error page with no `.results`, silently truncating
  the list so the frozen 24.9.2.42 fell outside the window and the run
  failed. skopeo is already in build-deps and is how the sibling
  generators (postgres, redis, mongodb, opensearch, kubernetes) fetch.
- Make a frozen default tag missing from the registry a hard error
  instead of silently falling back to a newer patch, which would move
  the default image for existing installs.
- Restore 0644 on the regenerated files (mktemp's 0600 survived the mv).
- Exclude /hack from the chart tarball via .helmignore.
- Refresh files/versions.yaml: v25.8 -> 25.8.32.4, the true latest 25.8
  patch now visible with the complete tag list.
- bats: add a missing-frozen-tag hard-error case and make the atomicity
  test reach the resolution phase after a valid default rather than
  failing at the default-in-set check.

Signed-off-by: Alexey Artamonov <[email protected]>
(cherry picked from commit e707475)
Signed-off-by: Myasnikov Daniil <[email protected]>
Assisted-By: LLM
@myasnikovdaniil
myasnikovdaniil force-pushed the backport-3476-to-release-1.6 branch from 6dd4a82 to 6a87565 Compare September 3, 2026 14:00
@myasnikovdaniil
myasnikovdaniil marked this pull request as ready for review September 3, 2026 14:01
@myasnikovdaniil
myasnikovdaniil merged commit 9c16916 into release-1.6 Sep 3, 2026
9 checks passed
@myasnikovdaniil
myasnikovdaniil deleted the backport-3476-to-release-1.6 branch September 3, 2026 14:01
@github-actions github-actions Bot added size/XL This PR changes 500-999 lines, ignoring generated files area/database Issues or PRs related to managed databases (postgres, mariadb, redis, etcd, kafka, clickhouse) area/release Issues or PRs related to release tooling (changelog, backport, release pipeline) kind/feature Categorizes issue or PR as related to a new feature labels Sep 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/database Issues or PRs related to managed databases (postgres, mariadb, redis, etcd, kafka, clickhouse) area/release Issues or PRs related to release tooling (changelog, backport, release pipeline) kind/feature Categorizes issue or PR as related to a new feature size/XL This PR changes 500-999 lines, ignoring generated files

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants