7
7
- synchronize
8
8
- reopened
9
9
10
+ permissions : {}
11
+
10
12
jobs :
11
13
lint-chart :
12
14
runs-on : ubuntu-latest
13
15
steps :
14
16
- name : Harden Runner
15
- uses : step-security/harden-runner@1b05615854632b887b69ae1be8cbefe72d3ae423 # v2.6.0
17
+ uses : step-security/harden-runner@5c7944e73c4c2a096b17a9cb74d65b6c2bbafbde # v2.9.1
16
18
with :
17
19
egress-policy : audit
18
20
- name : Checkout
19
- uses : actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3
21
+ uses : actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
20
22
with :
21
23
fetch-depth : 0
22
24
25
27
with :
26
28
version : v3.4.0
27
29
28
- - uses : actions/setup-python@61a6322f88396a6271a6ee3565807d608ecaddd1 # v4.7 .0
30
+ - uses : actions/setup-python@f677139bbe7f9c59b41e40162b753c062f5d49a3 # v5.2 .0
29
31
with :
30
32
python-version : 3.7
31
33
@@ -46,22 +48,15 @@ jobs:
46
48
runs-on : ubuntu-latest
47
49
steps :
48
50
- name : Harden Runner
49
- uses : step-security/harden-runner@1b05615854632b887b69ae1be8cbefe72d3ae423 # v2.6.0
51
+ uses : step-security/harden-runner@5c7944e73c4c2a096b17a9cb74d65b6c2bbafbde # v2.9.1
50
52
with :
51
53
egress-policy : audit
52
54
- name : Checkout
53
- uses : actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3
55
+ uses : actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
54
56
- name : Setup Go
55
- uses : actions/setup-go@93397bea11091df50f3d7e59dc26a7711a8bcfbe # v4.1.0
56
- with :
57
- go-version : 1.20.x
58
- - name : Restore Go cache
59
- uses : actions/cache@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3.3.1
57
+ uses : actions/setup-go@0a12ed9d6a96ab950c8f026ed9f722fe0da7ef32 # v5.0.2
60
58
with :
61
- path : ~/go/pkg/mod
62
- key : ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
63
- restore-keys : |
64
- ${{ runner.os }}-go-
59
+ go-version : 1.22.x
65
60
- name : fmt
66
61
run : make fmt
67
62
- name : vet
@@ -81,28 +76,21 @@ jobs:
81
76
strategy :
82
77
matrix :
83
78
kubernetes-version :
84
- - " 1.25"
85
- - " 1.26"
86
79
- " 1.27"
87
80
- " 1.28"
81
+ - " 1.29"
82
+ - " 1.30"
88
83
steps :
89
84
- name : Harden Runner
90
- uses : step-security/harden-runner@1b05615854632b887b69ae1be8cbefe72d3ae423 # v2.6.0
85
+ uses : step-security/harden-runner@5c7944e73c4c2a096b17a9cb74d65b6c2bbafbde # v2.9.1
91
86
with :
92
87
egress-policy : audit
93
88
- name : Checkout
94
- uses : actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3
89
+ uses : actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
95
90
- name : Setup Go
96
- uses : actions/setup-go@93397bea11091df50f3d7e59dc26a7711a8bcfbe # v4.1.0
97
- with :
98
- go-version : 1.20.x
99
- - name : Restore Go cache
100
- uses : actions/cache@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3.3.1
91
+ uses : actions/setup-go@0a12ed9d6a96ab950c8f026ed9f722fe0da7ef32 # v5.0.2
101
92
with :
102
- path : ~/go/pkg/mod
103
- key : ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
104
- restore-keys : |
105
- ${{ runner.os }}-go-
93
+ go-version : 1.22.x
106
94
- name : run test
107
95
run : make test ENVTEST_K8S_VERSION=${{ matrix.kubernetes-version }}
108
96
@@ -112,22 +100,15 @@ jobs:
112
100
profiles : ${{ steps.profiles.outputs.matrix }}
113
101
steps :
114
102
- name : Harden Runner
115
- uses : step-security/harden-runner@1b05615854632b887b69ae1be8cbefe72d3ae423 # v2.6.0
103
+ uses : step-security/harden-runner@5c7944e73c4c2a096b17a9cb74d65b6c2bbafbde # v2.9.1
116
104
with :
117
105
egress-policy : audit
118
106
- name : Checkout
119
- uses : actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3
107
+ uses : actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
120
108
- name : Setup Go
121
- uses : actions/setup-go@93397bea11091df50f3d7e59dc26a7711a8bcfbe # v4.1.0
109
+ uses : actions/setup-go@0a12ed9d6a96ab950c8f026ed9f722fe0da7ef32 # v5.0.2
122
110
with :
123
- go-version : 1.20.x
124
- - name : Restore Go cache
125
- uses : actions/cache@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3.3.1
126
- with :
127
- path : ~/go/pkg/mod
128
- key : ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
129
- restore-keys : |
130
- ${{ runner.os }}-go-
111
+ go-version : 1.22.x
131
112
- name : build
132
113
run : make build
133
114
- name : Check if working tree is dirty
@@ -144,7 +125,7 @@ jobs:
144
125
run : |
145
126
docker save --output db-controller-container.tar db-controller:latest
146
127
- name : Upload image
147
- uses : actions/upload-artifact@0b7f8abb1508181956e8e162db84b466c27e18ce # v3.1.2
128
+ uses : actions/upload-artifact@50769540e7f4bd5e21e526ee35c689e35e0d6874 # v4.4.0
148
129
with :
149
130
name : db-controller-container
150
131
path : db-controller-container.tar
@@ -164,21 +145,21 @@ jobs:
164
145
profile : ${{ fromJson(needs.build.outputs.profiles) }}
165
146
steps :
166
147
- name : Harden Runner
167
- uses : step-security/harden-runner@8ca2b8b2ece13480cda6dacd3511b49857a23c09 # v2.5 .1
148
+ uses : step-security/harden-runner@5c7944e73c4c2a096b17a9cb74d65b6c2bbafbde # v2.9 .1
168
149
with :
169
150
egress-policy : audit
170
151
- name : Checkout
171
- uses : actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3
152
+ uses : actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
172
153
- name : Setup Go
173
- uses : actions/setup-go@93397bea11091df50f3d7e59dc26a7711a8bcfbe # v4.1.0
154
+ uses : actions/setup-go@0a12ed9d6a96ab950c8f026ed9f722fe0da7ef32 # v5.0.2
174
155
with :
175
- go-version : 1.20 .x
156
+ go-version : 1.22 .x
176
157
- name : Setup Kubernetes
177
158
uses : engineerd/setup-kind@aa272fe2a7309878ffc2a81c56cfe3ef108ae7d0 # v0.5.0
178
159
with :
179
160
version : v0.17.0
180
161
- name : Download db-controller container
181
- uses : actions/download-artifact@9bc31d5ccc31df68ecc42ccf4149144866c47d8a # v3.0.2
162
+ uses : actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
182
163
with :
183
164
name : db-controller-container
184
165
path : /tmp
@@ -187,7 +168,7 @@ jobs:
187
168
docker load --input /tmp/db-controller-container.tar
188
169
docker image ls -a
189
170
- name : Setup Kustomize
190
- uses : imranismail/setup-kustomize@6691bdeb1b0a3286fb7f70fd1423c10e81e5375f # v2.0 .0
171
+ uses : imranismail/setup-kustomize@2ba527d4d055ab63514ba50a99456fc35684947f # v2.1 .0
191
172
- name : Run test
192
173
run : |
193
174
make kind-test TEST_PROFILE=${{ matrix.profile }}
@@ -198,37 +179,38 @@ jobs:
198
179
kubectl -n db-system describe pods
199
180
kubectl -n db-system get all
200
181
kubectl -n db-system logs deploy/db-controller
201
-
182
+ kubectl -n db-system get dbinstance -o yaml
183
+
202
184
test-chart :
203
185
runs-on : ubuntu-latest
204
186
needs :
205
187
- build
206
188
- lint-chart
207
189
steps :
208
190
- name : Harden Runner
209
- uses : step-security/harden-runner@1b05615854632b887b69ae1be8cbefe72d3ae423 # v2.6.0
191
+ uses : step-security/harden-runner@5c7944e73c4c2a096b17a9cb74d65b6c2bbafbde # v2.9.1
210
192
with :
211
193
egress-policy : audit
212
194
- name : Checkout
213
- uses : actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3
195
+ uses : actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
214
196
with :
215
197
fetch-depth : 0
216
198
217
199
- name : Set up Helm
218
200
uses : azure/setup-helm@5119fcb9089d432beecbf79bb2c7915207344b78 # v3.5
219
201
220
- - uses : actions/setup-python@61a6322f88396a6271a6ee3565807d608ecaddd1 # v4.7 .0
202
+ - uses : actions/setup-python@f677139bbe7f9c59b41e40162b753c062f5d49a3 # v5.2 .0
221
203
with :
222
204
python-version : 3.7
223
205
224
206
- name : Set up chart-testing
225
207
uses : helm/chart-testing-action@e6669bcd63d7cb57cb4380c33043eebe5d111992 # v2.6.1
226
208
227
209
- name : Create kind cluster
228
- uses : helm/kind-action@dda0770415bac9fc20092cacbc54aa298604d140 # v1.8 .0
210
+ uses : helm/kind-action@0025e74a8c7512023d06dc019c617aa3cf561fde # v1.10 .0
229
211
230
212
- name : Download db-controller container
231
- uses : actions/download-artifact@9bc31d5ccc31df68ecc42ccf4149144866c47d8a # v3.0.2
213
+ uses : actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
232
214
with :
233
215
name : db-controller-container
234
216
path : /tmp
@@ -242,3 +224,9 @@ jobs:
242
224
243
225
- name : Run chart-testing (install)
244
226
run : ct install --target-branch=master --chart-dirs chart
227
+
228
+ test-success :
229
+ runs-on : ubuntu-latest
230
+ needs : [test, e2e-tests]
231
+ steps :
232
+ - run : echo "all tests succeeded"
0 commit comments