forked from wunderio/csi-rclone
-
Notifications
You must be signed in to change notification settings - Fork 3
54 lines (52 loc) · 1.76 KB
/
publish-chart.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
name: Publish chart
on:
push:
branches:
- "**"
tags:
- "*.*.*"
workflow_dispatch:
jobs:
publish-chart:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: 3.11
- uses: azure/setup-helm@v3
with:
token: ${{secrets.GITHUB_TOKEN }}
- name: install dependencies
run: pip install chartpress
- uses: cachix/install-nix-action@v22
with:
nix_path: nixpkgs=channel:nixos-unstable
- name: Flake check
run: nix flake check
- name: Publish images
uses: workflow/[email protected]
env:
DOCKER_USERNAME: ${{ secrets.RENKU_DOCKER_USERNAME }}
DOCKER_PASSWORD: ${{ secrets.RENKU_DOCKER_PASSWORD }}
with:
flakes-from-devshell: true
flakes: .#csi-rclone-container-layerd
script: |
export TAG=$(echo ${GITHUB_REF} |cut -d/ -f3)
nix build .#csi-rclone-container-layerd && ./result | docker load
docker tag csi-rclone:latest renku/csi-rclone:latest
docker tag csi-rclone:latest renku/csi-rclone:${TAG}
echo ${DOCKER_PASSWORD}|docker login -u ${DOCKER_USERNAME} --password-stdin
docker push renku/csi-rclone:latest
docker push renku/csi-rclone:${TAG}
- name: Publish chart
run: |
cd deploy
git config --global user.email "[email protected]"
git config --global user.name "Renku Bot"
export TAG=$(echo ${GITHUB_REF} |cut -d/ -f3)
helm dep update csi-rclone
chartpress --tag $TAG
helm lint csi-rclone
chartpress --tag $TAG --no-build --publish-chart