Skip to content

Commit d5e3f2c

Browse files
authored
Add quotas-plugin to tests and move kubectl instead copy (#3)
* Add quotas-plugin to tests and move kubectl instead copy Signed-off-by: Jakub Stejskal <xstejs24@gmail.com> * Some minor fixups and testing changes Signed-off-by: Jakub Stejskal <xstejs24@gmail.com> * Fix checkout Signed-off-by: Jakub Stejskal <xstejs24@gmail.com> * Use proper imagesDir for test-clients Signed-off-by: Jakub Stejskal <xstejs24@gmail.com> * Comment out test-clients Signed-off-by: Jakub Stejskal <xstejs24@gmail.com> * Add option to use ITs in other repos, update readme Signed-off-by: Jakub Stejskal <xstejs24@gmail.com> * Use strimzi ref for quotas plugin Signed-off-by: Jakub Stejskal <xstejs24@gmail.com> --------- Signed-off-by: Jakub Stejskal <xstejs24@gmail.com>
1 parent b55c196 commit d5e3f2c

5 files changed

Lines changed: 141 additions & 44 deletions

File tree

.github/actions/dependencies/setup-kind/setup-kind.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ function install_kubectl {
4646
TEST_KUBECTL_VERSION=$(curl -L -s https://dl.k8s.io/release/stable.txt)
4747
fi
4848
curl -Lo kubectl https://dl.k8s.io/release/${TEST_KUBECTL_VERSION}/bin/linux/${ARCH}/kubectl && chmod +x kubectl
49-
sudo cp kubectl /usr/local/bin
49+
sudo mv kubectl /usr/local/bin
5050

5151
if is_podman; then
5252
sudo ln -sf /usr/local/bin/kubectl /usr/bin/kubectl

.github/workflows/reusable-test-integrations.yml

Lines changed: 39 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@ on:
77
description: "Repository to checkout (e.g., strimzi/strimzi-kafka-bridge)"
88
required: true
99
type: string
10+
ref:
11+
description: "Repository ref to checkout (e.g., main)"
12+
required: true
13+
type: string
1014
architecture:
1115
description: "Architecture"
1216
required: true
@@ -47,6 +51,11 @@ on:
4751
description: "Flag whether it is Strimzi Operator build or not (should be set only in Strimzi Kafka Operator repo)"
4852
required: false
4953
type: boolean
54+
githubActionsRef:
55+
description: "Ref of strimzi/github-actions to use (tag, branch, or SHA). Leave empty for local calls within github-actions repo."
56+
required: false
57+
type: string
58+
default: ""
5059

5160
# Declare default permissions as read only
5261
permissions:
@@ -60,13 +69,16 @@ jobs:
6069
timeout-minutes: 30
6170
steps:
6271
- name: Checkout ${{ inputs.repo }}
63-
uses: actions/checkout@v4
72+
uses: actions/checkout@v6
6473
with:
6574
repository: ${{ inputs.repo }}
75+
ref: ${{ inputs.ref }}
6676

6777
- name: Checkout github-actions
68-
uses: actions/checkout@v4
78+
uses: actions/checkout@v6
6979
with:
80+
repository: strimzi/github-actions
81+
ref: ${{ inputs.githubActionsRef || github.sha }}
7082
path: github-actions
7183

7284
- name: Setup actions for testing
@@ -117,13 +129,16 @@ jobs:
117129
timeout-minutes: 20
118130
steps:
119131
- name: Checkout ${{ inputs.repo }}
120-
uses: actions/checkout@v4
132+
uses: actions/checkout@v6
121133
with:
122134
repository: ${{ inputs.repo }}
135+
ref: ${{ inputs.ref }}
123136

124137
- name: Checkout github-actions
125-
uses: actions/checkout@v4
138+
uses: actions/checkout@v6
126139
with:
140+
repository: strimzi/github-actions
141+
ref: ${{ inputs.githubActionsRef || github.sha }}
127142
path: github-actions
128143

129144
- name: Setup Nexus
@@ -221,13 +236,16 @@ jobs:
221236
timeout-minutes: 45
222237
steps:
223238
- name: Checkout ${{ inputs.repo }}
224-
uses: actions/checkout@v4
239+
uses: actions/checkout@v6
225240
with:
226241
repository: ${{ inputs.repo }}
242+
ref: ${{ inputs.ref }}
227243

228244
- name: Checkout github-actions
229-
uses: actions/checkout@v4
245+
uses: actions/checkout@v6
230246
with:
247+
repository: strimzi/github-actions
248+
ref: ${{ inputs.githubActionsRef || github.sha }}
231249
path: github-actions
232250

233251
- name: Setup actions for testing
@@ -258,13 +276,16 @@ jobs:
258276
timeout-minutes: 20
259277
steps:
260278
- name: Checkout ${{ inputs.repo }}
261-
uses: actions/checkout@v4
279+
uses: actions/checkout@v6
262280
with:
263281
repository: ${{ inputs.repo }}
282+
ref: ${{ inputs.ref }}
264283

265284
- name: Checkout github-actions
266-
uses: actions/checkout@v4
285+
uses: actions/checkout@v6
267286
with:
287+
repository: strimzi/github-actions
288+
ref: ${{ inputs.githubActionsRef || github.sha }}
268289
path: github-actions
269290

270291
- name: Setup actions for testing
@@ -307,13 +328,16 @@ jobs:
307328
timeout-minutes: 15
308329
steps:
309330
- name: Checkout ${{ inputs.repo }}
310-
uses: actions/checkout@v4
331+
uses: actions/checkout@v6
311332
with:
312333
repository: ${{ inputs.repo }}
334+
ref: ${{ inputs.ref }}
313335

314336
- name: Checkout github-actions
315-
uses: actions/checkout@v4
337+
uses: actions/checkout@v6
316338
with:
339+
repository: strimzi/github-actions
340+
ref: ${{ inputs.githubActionsRef || github.sha }}
317341
path: github-actions
318342

319343
- name: Setup actions for testing
@@ -368,13 +392,16 @@ jobs:
368392

369393
steps:
370394
- name: Checkout ${{ inputs.repo }}
371-
uses: actions/checkout@v4
395+
uses: actions/checkout@v6
372396
with:
373397
repository: ${{ inputs.repo }}
398+
ref: ${{ inputs.ref }}
374399

375400
- name: Checkout github-actions
376-
uses: actions/checkout@v4
401+
uses: actions/checkout@v6
377402
with:
403+
repository: strimzi/github-actions
404+
ref: ${{ inputs.githubActionsRef || github.sha }}
378405
path: github-actions
379406

380407
- name: Setup actions for testing

.github/workflows/test-dependencies.yml

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,6 @@ on:
77
push:
88
branches:
99
- "main"
10-
# TODO - Remove this after testing
11-
- "extract-actions"
1210
tags:
1311
- "*"
1412

@@ -26,7 +24,7 @@ jobs:
2624
name: Test install-docker
2725
runs-on: ubuntu-latest
2826
steps:
29-
- uses: actions/checkout@v4
27+
- uses: actions/checkout@v6
3028

3129
- name: Run install-docker action
3230
uses: ./.github/actions/dependencies/install-docker
@@ -56,7 +54,7 @@ jobs:
5654
- 'v3.20.0'
5755
- 'v3.16.0'
5856
steps:
59-
- uses: actions/checkout@v4
57+
- uses: actions/checkout@v6
6058

6159
- name: Run install-helm action
6260
uses: ./.github/actions/dependencies/install-helm
@@ -86,7 +84,7 @@ jobs:
8684
- '0.11.0'
8785
- '0.10.0'
8886
steps:
89-
- uses: actions/checkout@v4
87+
- uses: actions/checkout@v6
9088

9189
- name: Run install-shellcheck action
9290
uses: ./.github/actions/dependencies/install-shellcheck
@@ -117,7 +115,7 @@ jobs:
117115
- '1.0.0'
118116
- '1.20.0'
119117
steps:
120-
- uses: actions/checkout@v4
118+
- uses: actions/checkout@v6
121119

122120
- name: Run install-syft action
123121
uses: ./.github/actions/dependencies/install-syft
@@ -142,7 +140,7 @@ jobs:
142140
- 'v4.6.3'
143141
- 'v4.52.2'
144142
steps:
145-
- uses: actions/checkout@v4
143+
- uses: actions/checkout@v6
146144

147145
- name: Run install-yq action
148146
uses: ./.github/actions/dependencies/install-yq
@@ -166,7 +164,7 @@ jobs:
166164
javaVersion: ['17', '21']
167165
mavenVersion: ['3.9.9', '3.8.8']
168166
steps:
169-
- uses: actions/checkout@v4
167+
- uses: actions/checkout@v6
170168

171169
- name: Run setup-java action
172170
uses: ./.github/actions/dependencies/setup-java
@@ -211,7 +209,7 @@ jobs:
211209
workerNodes: 3
212210
expectedK8sVersion: "1.35"
213211
steps:
214-
- uses: actions/checkout@v4
212+
- uses: actions/checkout@v6
215213

216214
- name: Run setup-kind action
217215
uses: ./.github/actions/dependencies/setup-kind
@@ -307,7 +305,7 @@ jobs:
307305
- 'v1.30.0'
308306
- 'v1.35.0'
309307
steps:
310-
- uses: actions/checkout@v4
308+
- uses: actions/checkout@v6
311309

312310
- name: Run setup-minikube action
313311
uses: ./.github/actions/dependencies/setup-minikube

.github/workflows/test-integrations.yml

Lines changed: 30 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,6 @@ on:
77
push:
88
branches:
99
- "main"
10-
# TODO - Remove this after testing
11-
- "extract-actions"
1210
tags:
1311
- "*"
1412

@@ -31,6 +29,7 @@ jobs:
3129
project:
3230
# Strimzi Operator - Full pipeline with containers and Helm
3331
- repo: "strimzi/strimzi-kafka-operator"
32+
ref: "main"
3433
artifactSuffix: "operators"
3534
architecture: "amd64"
3635
buildContainers: true
@@ -44,6 +43,7 @@ jobs:
4443

4544
# Kafka Bridge - Full pipeline with containers
4645
- repo: "strimzi/strimzi-kafka-bridge"
46+
ref: "main"
4747
artifactSuffix: "kafka-bridge"
4848
architecture: "amd64"
4949
buildContainers: true
@@ -57,19 +57,21 @@ jobs:
5757

5858
# Access Operator - Full pipeline with containers
5959
- repo: "strimzi/kafka-access-operator"
60+
ref: "main"
6061
artifactSuffix: "access-operator"
6162
architecture: "amd64"
6263
buildContainers: true
6364
modules: "./,api"
6465
nexusCheck: "kafka-access-operator"
65-
javaVersion: "17"
66+
javaVersion: "21"
6667
helmChartName: "none"
6768
releaseVersion: "6.6.6"
6869
imagesDir: "access-operator-container-amd64.tar.gz"
6970
clusterOperatorBuild: false
7071

7172
# MQTT Bridge - Full pipeline with containers
7273
- repo: "strimzi/strimzi-mqtt-bridge"
74+
ref: "main"
7375
artifactSuffix: "mqtt-bridge"
7476
architecture: "amd64"
7577
buildContainers: true
@@ -83,6 +85,7 @@ jobs:
8385

8486
# Drain Cleaner - Full pipeline with containers and Helm
8587
- repo: "strimzi/drain-cleaner"
88+
ref: "main"
8689
artifactSuffix: "drain-cleaner"
8790
architecture: "amd64"
8891
buildContainers: true
@@ -96,6 +99,7 @@ jobs:
9699

97100
# Client Examples - Containers only (no Maven deploy)
98101
- repo: "strimzi/client-examples"
102+
ref: "main"
99103
artifactSuffix: "client-examples"
100104
architecture: "amd64"
101105
buildContainers: true
@@ -107,22 +111,23 @@ jobs:
107111
imagesDir: "*-amd64.tar.gz"
108112
clusterOperatorBuild: false
109113

110-
# Not compatible yet
111114
# # Test Clients - Containers only (no Maven deploy)
112115
# - repo: "strimzi/test-clients"
116+
# ref: "main"
113117
# artifactSuffix: "test-clients"
114118
# architecture: "amd64"
115119
# buildContainers: true
116120
# modules: "none"
117121
# nexusCheck: "none"
118-
# javaVersion: "17"
122+
# javaVersion: "21"
119123
# helmChartName: "none"
120124
# releaseVersion: "6.6.6"
121-
# imagesDir: "test-clients-amd64.tar.gz"
125+
# imagesDir: "./docker-images/container-archives"
122126
# clusterOperatorBuild: false
123-
127+
#
124128
# # Metrics Reporter - Java only (no containers)
125129
# - repo: "strimzi/metrics-reporter"
130+
# ref: "main"
126131
# artifactSuffix: "metrics-reporter"
127132
# architecture: "amd64"
128133
# buildContainers: false
@@ -133,22 +138,24 @@ jobs:
133138
# releaseVersion: "6.6.6"
134139
# imagesDir: "none"
135140
# clusterOperatorBuild: false
136-
#
137-
# # Kafka Quotas Plugin - Java only (no containers)
138-
# - repo: "strimzi/kafka-quotas-plugin"
139-
# artifactSuffix: "kafka-quotas-plugin"
140-
# architecture: "amd64"
141-
# buildContainers: false
142-
# modules: "./"
143-
# nexusCheck: "kafka-quotas-plugin"
144-
# javaVersion: "17"
145-
# helmChartName: "none"
146-
# releaseVersion: "6.6.6"
147-
# imagesDir: "none"
148-
# clusterOperatorBuild: false
149-
#
141+
142+
# Kafka Quotas Plugin - Java only (no containers)
143+
- repo: "strimzi/kafka-quotas-plugin"
144+
ref: "main"
145+
artifactSuffix: "kafka-quotas-plugin"
146+
architecture: "amd64"
147+
buildContainers: false
148+
modules: "./"
149+
nexusCheck: "kafka-quotas-plugin"
150+
javaVersion: "17"
151+
helmChartName: "none"
152+
releaseVersion: "6.6.6"
153+
imagesDir: "none"
154+
clusterOperatorBuild: false
155+
150156
# # Kafka Kubernetes Config Provider - Java only (no containers)
151157
# - repo: "strimzi/kafka-kubernetes-config-provider"
158+
# ref: "main"
152159
# artifactSuffix: "kafka-kubernetes-config-provider"
153160
# architecture: "amd64"
154161
# buildContainers: false
@@ -162,6 +169,7 @@ jobs:
162169

163170
# # Kafka OAuth - Java only (no containers)
164171
# - repo: "strimzi/strimzi-kafka-oauth"
172+
# ref: "main"
165173
# architecture: "amd64"
166174
# artifactName: "oauth-binaries"
167175
# modules: "./,oauth-common,oauth-client,oauth-server"
@@ -177,6 +185,7 @@ jobs:
177185
uses: ./.github/workflows/reusable-test-integrations.yml
178186
with:
179187
repo: ${{ matrix.project.repo }}
188+
ref: ${{ matrix.project.ref }}
180189
architecture: ${{ matrix.project.architecture }}
181190
artifactSuffix: ${{ matrix.project.artifactSuffix }}
182191
buildContainers: ${{ matrix.project.buildContainers }}

0 commit comments

Comments
 (0)