Skip to content

Commit

Permalink
Merge pull request #181 from jkroepke/oci-push
Browse files Browse the repository at this point in the history
publish new charts to GHCR OCI registry
  • Loading branch information
pierluigilenoci committed Feb 28, 2024
2 parents cbeceab + b117fcd commit 1d8900d
Showing 1 changed file with 22 additions and 1 deletion.
23 changes: 22 additions & 1 deletion .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ on:

jobs:
release:
permissions:
contents: write
packages: write
runs-on: ubuntu-latest
steps:
- name: Checkout
Expand All @@ -22,7 +25,7 @@ jobs:
- name: Install Helm
uses: azure/setup-helm@v3
with:
version: v3.10.3
version: v3.13.3

- name: Add Helm repositories
run: |
Expand All @@ -35,3 +38,21 @@ jobs:
env:
CR_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
CR_GENERATE_RELEASE_NOTES: true

# see https://github.com/helm/chart-releaser/issues/183
- name: Login to GitHub Container Registry
uses: docker/login-action@v1
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Push Charts to GHCR
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}/charts
done

0 comments on commit 1d8900d

Please sign in to comment.