-
Notifications
You must be signed in to change notification settings - Fork 141
32 lines (30 loc) · 1.15 KB
/
helm-release.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
name: helm-release
on:
workflow_dispatch:
permissions:
contents: read # for actions/checkout to fetch code
jobs:
publish:
runs-on: ubuntu-latest
permissions:
contents: write # needed to write releases
id-token: write # needed for keyless signing
packages: write # needed for ghcr access
steps:
- uses: actions/checkout@d632683dd7b4114ad314bca15554477dd762a938 # v4.0.0
- name: Publish Helm chart in GitHub Pages
uses: stefanprodan/helm-gh-pages@0ad2bb377311d61ac04ad9eb6f252fb68e207260 # v1.7.0
with:
token: ${{ secrets.GITHUB_TOKEN }}
- name: Login to GitHub Container Registry
uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 # v3.3.0
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Publish Helm OCI
run: |
VERSION=$(yq e '.version' charts/tofu-controller/Chart.yaml)
mkdir helm-release
helm package charts/tofu-controller/ -d helm-release
helm push helm-release/tofu-controller-${VERSION}.tgz oci://ghcr.io/flux-iac/charts