-
Notifications
You must be signed in to change notification settings - Fork 34
51 lines (45 loc) · 1.58 KB
/
release.yml
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
name: Release Charts
on:
push:
branches:
- main
paths:
- 'chart/**'
jobs:
release:
permissions:
contents: write # needed to write releases
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3
with:
fetch-depth: 0
- name: Configure Git
run: |
git config user.name "$GITHUB_ACTOR"
git config user.email "[email protected]"
- name: Install Helm
uses: azure/setup-helm@5119fcb9089d432beecbf79bb2c7915207344b78 # v3.5
with:
version: latest
- name: Prepare keys for signing
env:
SIGNING_KEY_BASE64: ${{ secrets.HELM_SIGNING_PRIVATE_KEY }}
SIGNING_KEY_PASSPHRASE_BASE64: ${{ secrets.HELM_SIGNING_PRIVATE_KEY_PASSPHRASE }}
KEY_PATH: ".gpg-dir"
SIGNING_KEY_PATH: ".gpg-dir/secring.gpg"
SIGNING_KEY_PASSPHRASE_PATH: ".gpg-dir/passphrase"
run: |
mkdir "$KEY_PATH"
base64 -d <<< "$SIGNING_KEY_BASE64" > "$SIGNING_KEY_PATH"
base64 -d <<< "$SIGNING_KEY_PASSPHRASE_BASE64" > "$SIGNING_KEY_PASSPHRASE_PATH"
echo "CR_PASSPHRASE_FILE=$SIGNING_KEY_PASSPHRASE_PATH" >> "$GITHUB_ENV"
echo "CR_KEYRING=$SIGNING_KEY_PATH" >> "$GITHUB_ENV"
- name: Run chart-releaser
uses: helm/chart-releaser-action@be16258da8010256c6e82849661221415f031968 # v1.5.0
with:
charts_dir: chart
config: cr.yaml
env:
CR_TOKEN: "${{ secrets.GITHUB_TOKEN }}"