Files
helm-charts-hardened/.github/workflows/helm-release.yaml
T
dependabot[bot] ba99ab3eb3 Bump docker/login-action from 4.5.0 to 4.5.1 (#893)
Bumps [docker/login-action](https://github.com/docker/login-action) from 4.5.0 to 4.5.1.
- [Release notes](https://github.com/docker/login-action/releases)
- [Commits](https://github.com/docker/login-action/compare/v4.5.0...v4.5.1)

---
updated-dependencies:
- dependency-name: docker/login-action
  dependency-version: 4.5.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-07-27 06:53:03 -07:00

75 lines
2.2 KiB
YAML

name: Release Helm Charts
on:
push:
branches:
- release
paths:
- '.github/workflows/helm-release.yaml'
- 'charts/**'
jobs:
release:
runs-on: ubuntu-22.04
permissions:
contents: write
packages: write
id-token: write
steps:
- name: Checkout
uses: actions/[email protected]
with:
fetch-depth: 0
- name: Configure Git
run: |
git config user.name "$GITHUB_ACTOR"
git config user.email "[email protected]"
- name: Setup cosign
uses: sigstore/[email protected]
with:
cosign-release: v2.2.3
- name: Set up Helm
uses: azure/setup-helm@v5
with:
version: v3.10.3
- name: Add required Helm repos for release packaging
run: |
helm repo add smallstep https://smallstep.github.io/helm-charts/
- name: Run chart-releaser
uses: helm/[email protected]
env:
CR_TOKEN: '${{ secrets.GITHUB_TOKEN }}'
- name: Login to GitHub Container Registry
uses: docker/[email protected]
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Push charts to GHCR and sign
# when filling gaps with previously released charts, cr would create
# nothing in .cr-release-packages/, and the original globbing character
# would be preserved, causing a non-zero exit. Set nullglob to fix this
run: |
shopt -s nullglob
for pkg in .cr-release-packages/*; do
if [ -z "${pkg:-}" ]; then
break
fi
helm push "${pkg}" oci://ghcr.io/"${GITHUB_REPOSITORY_OWNER}"/helm-charts |& tee .digest
file="${pkg##*/}" # extracts file name from full directory path
name="${file%-*}" # extracts chart name from filename
digest="$(awk -F "[, ]+" '/Digest/{print $NF}' < .digest)"
cosign sign ghcr.io/"${GITHUB_REPOSITORY_OWNER}"/helm-charts/"${name}"@"${digest}"
done
env:
COSIGN_YES: true