-
Notifications
You must be signed in to change notification settings - Fork 3
45 lines (37 loc) · 1.24 KB
/
main.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
33
34
35
36
37
38
39
40
41
42
43
44
45
name: Build
on: [push]
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install Helm
run: |
curl https://raw.githubusercontent.com/helm/helm/master/scripts/get-helm-3 | bash
helm plugin install https://github.com/hayorov/helm-gcs
- name: Lint chart
run: |
helm lint .
release:
needs: lint
if: github.ref == 'refs/heads/master'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install Helm
run: |
curl https://raw.githubusercontent.com/helm/helm/master/scripts/get-helm-3 | bash
helm plugin install https://github.com/hayorov/helm-gcs
- name: Dump GCloud auth key
run: |
cat <<'EOF' > gcloud_auth_key.json
${{ secrets.GCLOUD_AUTH_KEY }}
EOF
- name: Release chart
env:
GOOGLE_APPLICATION_CREDENTIALS: ${{ github.workspace }}/gcloud_auth_key.json
run: |
helm repo add hahow gs://hahow-helm-charts
helm repo update
PACKAGE_FILE_PATH=$(helm package . | sed 's/^Successfully packaged chart and saved it to: //')
helm gcs push $(basename ${PACKAGE_FILE_PATH}) hahow --public