Skip to content

chart: make deploy/helm/radar canonical + auto-sync to helm-charts#599

Merged
nadaverell merged 3 commits intomainfrom
radar/canonicalize-helm-chart
May 1, 2026
Merged

chart: make deploy/helm/radar canonical + auto-sync to helm-charts#599
nadaverell merged 3 commits intomainfrom
radar/canonicalize-helm-chart

Conversation

@nadaverell
Copy link
Copy Markdown
Contributor

@nadaverell nadaverell commented May 1, 2026

Why

The Radar Helm chart was living in two places that had drifted:

  • deploy/helm/radar/ in this repo — Chart.yaml stuck at v0.6.9 with stale metadata, but clusterrole.yaml had ClusterAPI / Contour / Trivy CRD groups wired up.
  • skyhook-io/helm-charts/charts/radar/ — published to ArtifactHub at v1.5.x with proper metadata, but missing those three CRD groups in values.yaml. Users installing from the public repo never got the RBAC grants.

The existing helm job in .github/workflows/release.yml already auto-syncs deploy/helm/radar/helm-charts/charts/radar/ on every Radar release. The drift came from someone hand-editing helm-charts after the last release — those hand-edits were going to be clobbered the next time release.yml ran. This PR resolves that by making the canonical copy contain everything, so the next release-time sync is correct.

What changes

  1. Adopt the published 1.5.x lineage here: ArtifactHub annotations, radarhq.io URLs, full metadata. Bump Chart.yaml to 1.5.10.
  2. Add values.schema.json — Helm validates user-supplied values at install/upgrade time (catches typos, bad enums, out-of-range ports), and ArtifactHub displays a "Values schema" badge. additionalProperties: true on service / persistence / auth.oidc / mcp / traffic so future fields don't break user configs.
  3. README pointer — clarify that this dir is canonical and release.yml handles publishing.
  4. Harden the helm job in release.yml (follow-up from review):
    • Extend the chart-version sed to also rewrite the image tag inside artifacthub.io/images: (previously hard-coded at 1.5.7 — would have advertised a stale image on every future release).
    • Fail fast if helm-charts already has the chart tag radar-$VERSION before pushing. helm/chart-releaser-action silently skips on tag collision; the workflow would otherwise return success but users' helm repo update would see nothing new.
  5. Drop the manual chart-edit step from DEVELOPMENT.mdrelease.yml rewrites Chart.yaml automatically; manual edits race with the release machinery.

No new CI infra needed; the existing release.yml helm job already syncs on every release.

Net effect for end users (after next Radar release)

  • ArtifactHub schema badge lights up.
  • ClusterAPI / Contour / Trivy CRDs become readable out of the box.
  • ArtifactHub image annotation shows the actual published version (was hard-coded 1.5.7).
  • All previously hand-added ArtifactHub annotations preserved (icon, screenshots, links, category).

Sequencing with skyhook-io/helm-charts#11

skyhook-io/helm-charts#11 ships the values schema standalone at v1.5.9 so the badge lights up immediately. After that lands, helm-charts will hold tag radar-1.5.9. The next Radar release must therefore be ≥ v1.5.10 — the new tag-collision guard will fail the helm job otherwise, with a clear error message.

Test plan

  • helm lint deploy/helm/radar passes
  • helm template with default values passes the new schema
  • helm template --set rbac.crdGroups.clusterApi=true --set rbac.crdGroups.contour=true --set rbac.crdGroups.trivy=true renders the expected RBAC rules
  • Schema rejects bad enums (timeline.storage=invalid, auth.mode=bogus) and out-of-range service.port=99999
  • Image-annotation sed pattern verified against the real Chart.yaml (rewrites radar:1.5.7radar:<release-version> cleanly)
  • After helm-charts#11 merges: ArtifactHub shows schema badge at v1.5.9
  • Next Radar release at v1.5.10+: ArtifactHub shows the new chart with all three CRD groups, schema, and updated image annotation

The chart lived in two places — here and skyhook-io/helm-charts/charts/radar
— and had drifted (radar copy stuck at 0.6.9 with stale metadata; published
copy at 1.5.x missing the ClusterAPI/Contour/Trivy CRD groups that exist
in this repo's clusterrole.yaml). Single-source-of-truth now lives here.

- Replace this chart's Chart.yaml/values.yaml with the published metadata
  (1.5.x lineage, ArtifactHub annotations, radarhq.io URLs).
- Bump to 1.5.10 — picks up the new values.schema.json plus the three
  extra CRD groups that were already wired into clusterrole.yaml but
  missing from the published values.yaml.
- Add values.schema.json: Helm validates user values at install/upgrade
  and ArtifactHub shows a 'Values schema' badge.
- New workflow: on push to main touching deploy/helm/radar/**, mirror
  the chart into skyhook-io/helm-charts/charts/radar/ and open a PR.
  Requires a HELM_CHARTS_SYNC_TOKEN secret (fine-grained PAT scoped to
  helm-charts with Contents + Pull-requests rw).
@nadaverell nadaverell requested a review from hisco as a code owner May 1, 2026 21:06
The helm job in .github/workflows/release.yml already clones helm-charts
on every Radar release, overwrites charts/radar/ with deploy/helm/radar/,
and pushes to main. Adding a separate sync workflow on Chart.yaml changes
duplicates that path with no real benefit — chart-only edits between
releases are rare, and waiting for the next release picks them up.
Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit e619f23. Configure here.

Comment thread deploy/helm/radar/Chart.yaml
…llision

Three follow-ups from the chart canonicalization review:

- Extend the chart-version sed to also rewrite the image tag inside the
  artifacthub.io/images annotation. Previously hard-coded at 1.5.7;
  ArtifactHub would otherwise advertise a stale image version on every
  future release.
- Fail fast if helm-charts already has tag radar-$VERSION before pushing.
  helm/chart-releaser-action skips packaging on tag collision, so a
  successful workflow run could silently fail to publish a new chart and
  users' 'helm repo update' would never see the new contents.
- Drop the manual 'update Helm chart appVersion' step from
  DEVELOPMENT.md — the helm job rewrites it automatically and a manual
  edit only races with the release machinery.
@nadaverell nadaverell merged commit 6f64b6d into main May 1, 2026
8 checks passed
@nadaverell nadaverell deleted the radar/canonicalize-helm-chart branch May 1, 2026 21:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant