-
-
Notifications
You must be signed in to change notification settings - Fork 151
49 lines (46 loc) · 1.21 KB
/
charts-deployment.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
name: publish charts to github pages
on:
workflow_dispatch:
push:
paths:
- 'ops/**'
branches:
- main
jobs:
deployment:
name: Build & Deployment
runs-on: ubuntu-latest
steps:
- name: Checkout routr repo
uses: actions/checkout@v4
with:
path: routr
ref: gh-pages
- name: Save charts directory
run: |
mkdir -p /tmp/charts
cp -a routr/charts/* /tmp/charts
- name: Checkout repo
uses: actions/checkout@v4
with:
persist-credentials: false
fetch-depth: 0
- name: Set up Helm
uses: azure/setup-helm@v3
with:
version: latest
token: ${{ secrets.DEPLOY_KEY }}
- name: Package charts
run: |
mv /tmp/charts charts
helm package ops/charts/connect -d charts
helm repo index charts --merge charts/index.yaml
- name: Build sources
run: mkdir -p public && mv charts public/charts
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.DEPLOY_KEY }}
publish_dir: ./public
publish_branch: gh-pages
keep_files: true