Skip to content

Commit

Permalink
Prepare test-clients repository for the first release (#12)
Browse files Browse the repository at this point in the history
Signed-off-by: Lukas Kral <[email protected]>
  • Loading branch information
im-konge authored Oct 1, 2021
1 parent aaec80f commit 829c4e1
Show file tree
Hide file tree
Showing 13 changed files with 37 additions and 11 deletions.
17 changes: 17 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,14 +1,31 @@
RELEASE_VERSION ?= latest

include ./Makefile.os

SUBDIRS=kafka/consumer kafka/producer kafka/streams kafka/admin http/http-consumer http/http-producer
DOCKER_TARGETS=docker_build docker_push docker_tag

all: $(SUBDIRS)
build: $(SUBDIRS)
clean: $(SUBDIRS)
release: release_examples release_maven

$(DOCKER_TARGETS): $(SUBDIRS)

$(SUBDIRS):
$(MAKE) -C $@ $(MAKECMDGOALS)

next_version:
mvn versions:set -DnewVersion=$(shell echo $(NEXT_VERSION) | tr a-z A-Z)
mvn versions:commit

release_examples:
echo "Changing images in examples to: $(RELEASE_VERSION)"
$(FIND) ./examples -name '*.yaml' -type f -exec $(SED) -i '/image: "\?quay.io\/strimzi-test-clients\/[a-zA-Z0-9_.-]\?\+:[a-zA-Z0-9_.-]\+-kafka-[0-9.]\+"\?/s/:[a-zA-Z0-9_.-]\+-kafka-\([0-9.]\+\)/:$(RELEASE_VERSION)-kafka-\1/g' {} \;

release_maven:
echo "Update pom versions to: $(RELEASE_VERSION)"
mvn versions:set -DnewVersion=$(shell echo $(RELEASE_VERSION) | tr a-z A-Z)
mvn versions:commit

.PHONY: all $(SUBDIRS) $(DOCKER_TARGETS)
9 changes: 9 additions & 0 deletions Makefile.os
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
FIND = find
SED = sed

UNAME_S := $(shell uname -s)

ifeq ($(UNAME_S),Darwin)
FIND = gfind
SED = gsed
endif
2 changes: 1 addition & 1 deletion examples/http/http-consumer.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ spec:
value: "100"
- name: LOG_LEVEL
value: DEBUG
image: quay.io/strimzi-test-clients/test-client-http-consumer:latest
image: quay.io/strimzi-test-clients/test-client-http-consumer:latest-kafka-3.0.0
imagePullPolicy: IfNotPresent
name: http-consumer
restartPolicy: "Never"
2 changes: 1 addition & 1 deletion examples/http/http-producer.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ spec:
value: "100"
- name: LOG_LEVEL
value: DEBUG
image: quay.io/strimzi-test-clients/test-client-http-producer:latest
image: quay.io/strimzi-test-clients/test-client-http-producer:latest-kafka-3.0.0
imagePullPolicy: IfNotPresent
name: http-producer
restartPolicy: "Never"
2 changes: 1 addition & 1 deletion examples/kafka/admin-client/alter-topics.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ spec:
value: "100"
- name: LOG_LEVEL
value: DEBUG
image: quay.io/strimzi-test-clients/test-client-kafka-admin:latest
image: quay.io/strimzi-test-clients/test-client-kafka-admin:latest-kafka-3.0.0
imagePullPolicy: IfNotPresent
name: alter-admin-client
restartPolicy: "Never"
2 changes: 1 addition & 1 deletion examples/kafka/admin-client/create-topics.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ spec:
value: "100"
- name: LOG_LEVEL
value: DEBUG
image: quay.io/strimzi-test-clients/test-client-kafka-admin:latest
image: quay.io/strimzi-test-clients/test-client-kafka-admin:latest-kafka-3.0.0
imagePullPolicy: IfNotPresent
name: create-admin-client
restartPolicy: "Never"
2 changes: 1 addition & 1 deletion examples/kafka/admin-client/delete-topics.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ spec:
value: "100"
- name: LOG_LEVEL
value: DEBUG
image: quay.io/strimzi-test-clients/test-client-kafka-admin:latest
image: quay.io/strimzi-test-clients/test-client-kafka-admin:latest-kafka-3.0.0
imagePullPolicy: IfNotPresent
name: delete-admin-client-1
restartPolicy: "Never"
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ spec:
sasl.mechanism=SCRAM-SHA-512
security.protocol=SASL_PLAINTEXT
sasl.jaas.config=org.apache.kafka.common.security.scram.ScramLoginModule required username="test-user" password="myPassword";
image: quay.io/strimzi-test-clients/test-client-kafka-admin:latest
image: quay.io/strimzi-test-clients/test-client-kafka-admin:latest-kafka-3.0.0
imagePullPolicy: IfNotPresent
name: delete-admin-client-offset-scram
restartPolicy: "Never"
Expand Down
2 changes: 1 addition & 1 deletion examples/kafka/admin-client/delete-with-offset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ spec:
value: "200"
- name: LOG_LEVEL
value: DEBUG
image: quay.io/strimzi-test-clients/test-client-kafka-admin:latest
image: quay.io/strimzi-test-clients/test-client-kafka-admin:latest-kafka-3.0.0
imagePullPolicy: IfNotPresent
name: delete-admin-client-with-offset
restartPolicy: "Never"
Expand Down
2 changes: 1 addition & 1 deletion examples/kafka/admin-client/list-topics.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ spec:
value: list
- name: LOG_LEVEL
value: DEBUG
image: quay.io/strimzi-test-clients/test-client-kafka-admin:latest
image: quay.io/strimzi-test-clients/test-client-kafka-admin:latest-kafka-3.0.0
imagePullPolicy: IfNotPresent
name: list-admin-client
restartPolicy: "Never"
Expand Down
2 changes: 1 addition & 1 deletion examples/kafka/kafka-consumer.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ spec:
value: my-group
- name: LOG_LEVEL
value: DEBUG
image: quay.io/strimzi-test-clients/test-client-kafka-consumer:latest
image: quay.io/strimzi-test-clients/test-client-kafka-consumer:latest-kafka-3.0.0
imagePullPolicy: IfNotPresent
name: kafka-consumer-client
restartPolicy: "Never"
2 changes: 1 addition & 1 deletion examples/kafka/kafka-producer.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ spec:
value: all
- name: LOG_LEVEL
value: DEBUG
image: quay.io/strimzi-test-clients/test-client-kafka-producer:latest
image: quay.io/strimzi-test-clients/test-client-kafka-producer:latest-kafka-3.0.0
imagePullPolicy: IfNotPresent
name: kafka-producer-client
restartPolicy: "Never"
2 changes: 1 addition & 1 deletion examples/kafka/kafka-streams.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ spec:
value: my-topic
- name: TARGET_TOPIC
value: my-topic-reversed
image: quay.io/strimzi-test-clients/test-client-kafka-streams:latest
image: quay.io/strimzi-test-clients/test-client-kafka-streams:latest-kafka-3.0.0
imagePullPolicy: IfNotPresent
name: kafka-streams-client
restartPolicy: "Never"

0 comments on commit 829c4e1

Please sign in to comment.