Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: Push nightly charts to ghcr.io #828

Merged
merged 1 commit into from
Jan 15, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 33 additions & 0 deletions .github/workflows/nightly-publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,36 @@ jobs:
REPO: ghcr.io/rancher
run: |
make image-push

publish_charts:
permissions:
packages: write # Required for pushing charts to ghcr.io
runs-on: ubuntu-latest
needs: publish_images
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Login to GHCR registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Install Helm
uses: azure/setup-helm@v4
with:
version: 3.8.0
- name: Set image tag
run: echo "TAG=$(date +'%Y%m%d')" >> "$GITHUB_ENV"
- name: Build charts
env:
REPO: ghcr.io/rancher # used in the Helm chart values.yaml
CHART_VERSION: ${{ env.TAG }} # chart version matches image tag
run: |
make charts
- name: Push charts
env:
CHART_VERSION: ${{ env.TAG }} # chart version matches image tag
run: |
helm push bin/rancher-aks-operator-$CHART_VERSION.tgz oci://ghcr.io/${{ github.repository_owner }}/rancher-aks-operator-chart
helm push bin/rancher-aks-operator-crd-$CHART_VERSION.tgz oci://ghcr.io/${{ github.repository_owner }}/rancher-aks-operator-crd-chart
Loading