Repository navigation
build: package the Helm chart in releases - #95
Conversation
Add a chart in deployment/ for Kubernetes and OpenShift: Deployment, Service, and an Ingress, Gateway API HTTPRoute or OpenShift Route, with an optional NetworkPolicy and PodDisruptionBudget. Settings come from camelCase values, the login providers only from an existing Secret; rendering fails without host, registry or Secret. The pod runs non-root with a read-only root file system; on OpenShift, user IDs and the seccomp profile are left to the cluster. CI lints and tests the chart (job chart) and installs it on kind with helm test (job chart-install); both are in the gate's needs. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Add "Helm chart" to the operator guide: installation from a release's checkout, the login providers' Secret and its fields, all values, exposing Krini, security on Kubernetes and OpenShift, upgrades and the chart tests. Link it from the README's quick start, the deployment and upgrade pages. Co-Authored-By: Claude Opus 5.5 <[email protected]>
- Admit the helm test pod through the NetworkPolicy. - No default ClusterIssuer: it's specific to a cluster. - Standard labels on pods; the version label follows krini.tag. - One helper for the port; value checks in their own template. - Run the ERR trap of the install script inside functions too. - Document that OpenShift needs the Ingress disabled for the Route, and the annotations and security contexts; more chart tests. Co-Authored-By: Claude Opus 5.5 <[email protected]>
- Allow `global` again, so that the chart works as a subchart. - Take the version label from krini.tag or the tag in krini.image, leave it out for digests, and keep it a valid label value. - Warn in the notes when OpenShift would serve the Ingress without TLS. - Check all labels of the test pod against the NetworkPolicy; rewrap. Co-Authored-By: Claude Opus 5.5 <[email protected]>
- Reject NetworkPolicy peers without selectors, and drop the label-based exception for the helm test pod (labels can be forged). - APP_ORIGIN must be an https origin, the privacy URLs https URLs, and /tmp's limit positive. - Document that several replicas need sticky sessions (refresh guard is per pod), the service prerequisites, the test pod after uninstall, and a provider example in the README. - Wait for the namespace deletion in the install script. Co-Authored-By: Claude Opus 5.5 <[email protected]>
scripts/package-chart.sh packages deployment/ for a release: version and appVersion are the release version, and the default image is the release workflow's image (also for forks with DOCKERHUB_ORG). The chart in the repository keeps its placeholders. The package is checked with helm lint --strict and a render with the CI values, and the script prints its file name and SHA-256 for GITHUB_OUTPUT. deployment/tests/test-package.sh tests it, and the chart job of CI runs the tests. The readiness job's checker moves to the commit of the publish-release action that release.yml pins next. Co-Authored-By: Claude Opus 5.5 <[email protected]>
prepare packages the chart with the version from the tag (scripts/package-chart.sh) and records its file name and SHA-256; release-image checks the artifact against them before it signs the image, and attests and signs the chart (Sigstore bundle) after tagging the image; publish checks the chart and the bundle and attaches both to the GitHub release. Immutable releases can't get assets after publishing, so publish uses the new assets input of the shared publish-release action, which creates a draft, uploads the files and publishes it last. The action is pinned to an unreleased commit until its next release. Co-Authored-By: Claude Opus 5.5 <[email protected]>
The operator guide installs and upgrades from the chart attached to the release (no checkout, no krini.tag), and describes how to verify it with gh attestation verify and cosign verify-blob. releasing.md describes the packaging, runs it in the pre-tag checks, and says that Chart.yaml keeps its placeholders. The README quick start, Upgrading, the chart README and the comments in Chart.yaml and values.yaml follow. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Review fixes: scripts/check-chart-artifact.sh replaces the two copies of the artifact check in release-image and publish, with tests in test-package.sh (also new: alpha/beta versions, a registry port, an upper-case image). release-image now attests and signs the chart before it tags the image, so that a signing failure leaves no tagged image without a signed chart. The publish-release pin moves to the action's commit with the asset name and digest checks; docs wording. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Second review round: the workflow header and releasing.md say that the chart is signed before the image is tagged; two more tests of the artifact check; the publish-release pin moves to the action's latest commit. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Reviewer's GuideUses of the APIPackage and validate a versioned Helm chart, then verify the chart and signature artifacts across the release jobs before publishing them.
UISwitch operator installation and upgrades to release chart assets and document how to verify their attestation and Sigstore signature.
ConfigurationKeep repository chart metadata as development placeholders and make the image-tag default clearly distinguish release packages from the development chart.
Add packaging and artifact-integrity checks to CI and pin the release-note checker to the shared action version used by releases.
DocumentationExplain release chart packaging, pre-tag validation, signing and publication, including recovery from a leftover draft.
Update the deployment README to distinguish the release package from the placeholder development chart and list the packaging test.
TestsExercise release packaging, fork image defaults, invalid inputs, package validation, and exact artifact integrity checks.
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
Move the four pins of the shared publish-release action from the unreleased branch commit to the released v1.2.0 of elixir-cloud-aai/.github. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## dev #95 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 20 20
Lines 566 566
Branches 161 161
=========================================
Hits 566 566 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
#92 is squash-merged into dev. Conflicts in its files are resolved to dev's version, with this branch's own changes re-applied on top, so the diff against dev holds only the changes of #94. Co-Authored-By: Claude Opus 5.5 <[email protected]>
A fake helm on PATH packages the chart with another appVersion than asked for, so the test covers the checks of the package in scripts/package-chart.sh, not only its arguments and success. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Upgrading says that a krini.tag in the values pins the old image, and the local pre-tag checks list sha256sum, which package-chart.sh needs. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Linked issuesChecked at commit 49357d2 #94 build: package the Helm chart in releases · 4 of 5 met · 1 to check by hand
|
There was a problem hiding this comment.
Hey - I've found 2 issues
Prompt for AI Agents
Please address the comments from this code review:
## Individual Comments
### Comment 1
<location path=".github/workflows/release.yml" line_range="566" />
<code_context>
with:
notes: docs/releases/${{ needs.prepare.outputs.version }}.md
commit: ${{ needs.prepare.outputs.sha }}
+ assets: |
+ dist/${{ needs.prepare.outputs.chart_file }}
+ dist/${{ needs.prepare.outputs.chart_file }}.sigstore.json
</code_context>
<issue_to_address>
**Interrupted publishes strand drafts**
When the publish job is canceled or its runner is lost after draft creation but before publication, the publish action leaves the draft behind, and a retry fails on that existing draft instead of completing the release; the release remains unpublished until someone deletes the draft manually.
Make retries detect and safely resume or remove a draft created by the interrupted workflow attempt.
</issue_to_address>
### Comment 2
<location path="README.md" line_range="76-78" />
<code_context>
kubectl create secret generic krini-login-providers -n <namespace> \
--from-file=login-providers=login-providers.json
-helm install krini deployment -n <namespace> \
+gh release download v<version> --repo elixir-cloud-aai/krini \
+ --pattern 'krini-<version>.tgz*'
+helm install krini krini-<version>.tgz -n <namespace> \
--set hostName=krini.example.org \
--set config.cloudRegistryUrl=https://registry.example.org \
</code_context>
<issue_to_address>
**Quick-start commands fail literally**
When a reader copies the commands without replacing the angle-bracket placeholder, bash treats `<version>` as input redirection rather than part of the release tag or filename, so the download and install commands do not use the chart asset shown in the example.
Define `version` in the snippet and interpolate it in the download pattern and chart filename.
</issue_to_address>Sourcery assessment
Needs a human reviewer. 1 finding to address first, and a packaging or artifact-check error could publish a publicly downloadable, officially signed chart that deploys the wrong image or configuration. Reverting the workflow won't retract a chart already attached to a release; the bounded issue would need a corrected release or asset remediation.
Blocking findings: .github/workflows/release.yml:566
If Publish release is cancelled after it created the draft, a re-run fails on the draft. Releasing says to delete the draft without --cleanup-tag and re-run the failed jobs. Found by Sourcery. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
Fork dry run of this release workflow passed (2026-11-16) in Every job succeeded, through to An earlier run (43848394136) pushed the wrong tag because of a mistake in our local commands. The workflow's version check refused it before anything was built or published, which tests that check as well. From our side this PR is ready for your review, @AnonymousXC. |
Set date-released to 2026-11-19 and reorder the CITATION.cff authors by lines added on dev (without lock files, public/ and src/components/ui/, as in #74). Add everything merged since the first draft to the release notes: TES tasks with the user's token (#90), the WES run details (#100), the minimal dashboard (#108), the Helm chart (#92, #95), the image end-to-end tests (#99), the deployment docs (#101), the Next.js update (#102) and the fixes #109 and #110. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Summary
The release workflow now packages the Helm chart and attaches it to the GitHub release, following cloud-registry's pattern.
preparepackagesdeployment/withscripts/package-chart.sh:versionandappVersionboth come from the tag.IMAGE_NAME, so a fork withDOCKERHUB_ORGpackages a chart that deploys its own image.helm lint --strictand a render with the CI values (version, appVersion,krini.image, rendered image).release-imagechecks the artifact against those records (scripts/check-chart-artifact.sh) before it signs anything. After signing the image, it attests the chart's provenance and signs it withcosign sign-blob(Sigstore bundle). It tags the image only after that, so a failed signing leaves the image untagged. It records the bundle's SHA-256.publish(still onlycontents: write) checks the chart and the bundle against the recorded checksums. It then attaches both via the newassetsinput of the sharedpublish-releaseaction.gh release create, which creates a draft, uploads them, publishes the release, and deletes the draft if anything fails.deployment/Chart.yamlkeeps its placeholders (0.0.0/dev). The tag is the only source of the version.chartjob also runsdeployment/tests/test-package.sh. Its 41 tests cover packaging, forks, invalid arguments, a package that fails the script's own checks, and the artifact check.krini.tag, and has a new section "Verifying the chart" (gh attestation verify,cosign verify-blob).releasing.mddescribes the packaging, adds it to the pre-tag checks, and notes the placeholders.values.yamlare updated.Closes #94
Uses elixir-cloud-aai/.github v1.2.0
The
assetsinput comes from elixir-cloud-aai/.github v1.2.0 (elixir-cloud-aai/.github#77, elixir-cloud-aai/.github#79).release.yml(2×), thereadinesschecker inci.ymlanddocs/development/releasing.mdpin its release commitbf3840c9c072aaf37d6cafe199aaa1994087d1ef # v1.2.0.Relation to #99
#99 (end-to-end tests on the image, #79) also changes
release.ymlanddocs/development/releasing.md: it adds ane2ejob thatrelease-imageneeds. In a test merge, the jobs andneedsmerge cleanly (needs: [prepare, push, smoke, e2e, scan]). Two text conflicts remain: the header comment ofrelease.ymland the paragraph on approving the release jobs inreleasing.md. Whichever PR merges second resolves them by naming both changes: the end-to-end tests next to the smoke test, and the chart signing before the image tag.Verification
dev, with Helm 3.22.1:deployment/tests/test-package.sh→ 41 tests, 0 failures.deployment/tests/test-chart.sh→ 99 tests, 0 failures.helm lint deployment --strict -f deployment/ci/test-values.yaml→ passed.deployment/tests/install-chart.shon a kind cluster, with the image built from the merged commit → ready,helm testpassed, upgraded to 2 replicas.actionlint(with shellcheck) andshellcheckon the scripts → clean.mkdocs build --strict→ clean.tsc --noEmitand the unit tests (259 passed, 100% coverage) → clean.git archiveof the commit):Package chartwith0.1.0andelixircloud, then0.1.0-rc1with a fork image.release-imageandpublishartifact checks, with a stand-in bundle.Chart.yamlstays0.0.0 dev.v0.0.1-rc1inuniqueg/krini): in progress with the maintainer, from a bundle rebuilt ondevat 0363f87. It is the only way to test the workflow wiring between jobs and the release created with assets.krini.tagnote in Upgrading, andsha256sumin the pre-tag prerequisites.Publish releaseleaves a draft of the tag, and a re-run then fails on it. That behaviour is in the shared action, so 49357d2 documents the recovery inreleasing.md: delete the draft without--cleanup-tag, then re-run the failed jobs.<version>, because the quick start uses angle-bracket placeholders throughout.dev) and on 49357d2, includingChart(withtest-package.sh),Chart installandCI passed.Declined review findings
release.yml,scan.yml,scripts/package-chart.sh; medium).prepareinrelease.ymlis the authority.scan.ymlalready had a copy before this PR, and the script checks again as defence in depth, which its header says. A shared snippet would changescan.yml, which is beyond build: package the Helm chart in releases #94.releasing.mdbesidesci.ymlandrelease.yml. Kept, because the pre-tag checks need the same version.releasing.mdpre-tag command namesdocker.io/elixircloud/krini. Forks are told right next to it to use their own image.assert_checkandassert_failsintest-package.sh. Kept separate: they run different commands and are short.🤖 Generated with Claude Code