-
Notifications
You must be signed in to change notification settings - Fork 106
61 lines (58 loc) · 1.69 KB
/
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
name: Release
on:
push:
tags:
- '[0-9]+.[0-9]+.[0-9]+'
jobs:
docker_job:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: release version
run: echo "VERSION=$(echo ${GITHUB_REF##*/})" >> $GITHUB_ENV
- uses: jaxxstorm/action-install-gh-release@v1
with:
repo: GoogleContainerTools/skaffold
tag: v1.38.0
cache: enable
extension-matching: disable
rename-to: skaffold
chmod: 0755
- uses: extractions/setup-just@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- uses: imjasonh/setup-crane@v0.1
- uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USER }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: build and publish image, create chart archive
run: |
just VERSION=${{ env.VERSION }} build-release
- name: upload helm artifact
uses: actions/upload-artifact@v4
with:
name: "helm"
path: "opa-kube-mgmt-${{ env.VERSION }}.tgz"
helm_job:
runs-on: ubuntu-latest
needs: docker_job
steps:
- uses: actions/checkout@v3
with:
ref: gh-pages
- name: download helm artifact
uses: actions/download-artifact@v4.1.7
id: download
with:
name: helm
path: /tmp/helm
- name: update helm index
run: |
helm repo index /tmp/helm --merge ./charts/index.yaml
mv -f /tmp/helm/* ./charts
- name: publish index and chart
uses: actions-js/push@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: gh-pages