diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 0b30d93..5609b74 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -9,6 +9,7 @@ jobs: release: permissions: contents: write + packages: write runs-on: ubuntu-latest steps: - name: Checkout @@ -33,7 +34,7 @@ jobs: - name: Install Helm uses: azure/setup-helm@v4 with: - version: v3.5.0 + version: v3.19.0 - name: Add Helm Repositories run: | @@ -48,3 +49,19 @@ jobs: env: CR_TOKEN: "${{ secrets.GITHUB_TOKEN }}" CR_SKIP_EXISTING: true + + - name: Login to GHCR + uses: docker/login-action@v3.2.0 + with: + registry: ghcr.io + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + + - name: Push chart to GHCR + if: ${{ hashFiles('.cr-release-packages/*.tgz') != '' }} + run: | + set -euo pipefail + shopt -s nullglob + for pkg in .cr-release-packages/*.tgz; do + helm push "${pkg}" "oci://ghcr.io/${{ github.repository_owner }}/helm-charts" + done diff --git a/charts/openfga/README.md b/charts/openfga/README.md index 717fed5..ec1577f 100644 --- a/charts/openfga/README.md +++ b/charts/openfga/README.md @@ -9,7 +9,7 @@ helm repo add openfga https://openfga.github.io/helm-charts helm install openfga openfga/openfga ``` -## Installing the Chart +## Installing the Chart via Helm Repository To install the chart with the release name `openfga`: @@ -22,6 +22,15 @@ This will deploy a 3-replica deployment of OpenFGA on the Kubernetes cluster usi > **Tip**: List all releases using `helm list` +## Installing the chart via OCI Image + +This chart is also available for installation from the GitHub OCI registry. It requires helm 3.8+. +To pull from the GitHub OCI registry, run: + +```sh +helm install openfga -f values.yaml oci://ghcr.io/openfga/helm-charts +``` + ## Customization If you wish to customize the OpenFGA deployment you may supply paremeters such as the ones listed in the [values.yaml](/charts/openfga/values.yaml). @@ -37,8 +46,8 @@ helm install openfga openfga/openfga \ ```yaml commonLabels: - app.example.com/system: permissions - app.example.com/domain: example + app.example.com/system: permissions + app.example.com/domain: example ``` ### Installing with Postgres