Skip to content

Merge pull request #152 from port-labs/PORT-11573-Bug-k8s-exporter-no… #176

Merge pull request #152 from port-labs/PORT-11573-Bug-k8s-exporter-no…

Merge pull request #152 from port-labs/PORT-11573-Bug-k8s-exporter-no… #176

Workflow file for this run

name: Release Charts
on:
workflow_dispatch:
push:
branches:
- main
permissions:
contents: write
packages: write
jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install Helm
uses: azure/setup-helm@5119fcb9089d432beecbf79bb2c7915207344b78 # v3.5
- name: Configure Git
run: |
git config user.name "$GITHUB_ACTOR"
git config user.email "[email protected]"
- name: Login to GHCR
uses: docker/login-action@465a07811f14bebb1938fbed4728c6a1ff8901fc # v2.2.0
with:
registry: ghcr.io
username: ${ GITHUB_REPOSITORY_OWNER }
password: ${{ secrets.GITHUB_TOKEN }}
- name: Run chart-releaser
uses: helm/[email protected]
with:
skip_existing: true
env:
CR_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
- name: Push chart 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