File tree Expand file tree Collapse file tree 1 file changed +11
-10
lines changed Expand file tree Collapse file tree 1 file changed +11
-10
lines changed Original file line number Diff line number Diff line change @@ -81,24 +81,25 @@ jobs:
81
81
if : ${{ ! endsWith(github.event.head_commit.message, '[skip ci]') }}
82
82
runs-on : ubuntu-latest
83
83
needs : build-package-images
84
-
85
- strategy :
86
- matrix :
87
- kustomization :
88
- - ./packages/base-node/.khz-k3s/kustomization.yaml
89
- - ./packages/archive/.khz-k3s/kustomization.yaml
90
-
91
84
steps :
92
85
- name : Install yq
93
86
uses : mikefarah/yq@master
94
87
with :
95
88
cmd : yq --version
96
89
97
- - name : Update image version tag
90
+ - name : Update version tags
91
+ run : |
92
+ function update_version_tag() {
93
+ file=$1
94
+ yq e '.images[0].newTag = "${{ github.sha }}"' -i $file
95
+ git add $kustomization
96
+ }
97
+ update_version_tag ./packages/base-node/.khz-k3s/kustomization.yaml
98
+ update_version_tag ./packages/archive/.khz-k3s/kustomization.yaml
99
+
100
+ - name : Deploy
98
101
run : |
99
102
git config --global user.email "juhani.pelli@gmail.com"
100
103
git config --global user.name "Juhani Pelli"
101
- yq e '.images[0].newTag = "${{ github.sha }}"' -i ${{ matrix.kustomization }}
102
- git add ${{ matrix.kustomization }}
103
104
git commit -m "Deploy ${{ github.sha }} [skip ci]"
104
105
git push origin ${{ github.event.repository.default_branch }}
You can’t perform that action at this time.
0 commit comments