This repository was archived by the owner on Mar 17, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +2
-0
lines changed
mqtt.kafka.broker/k8s/helm Expand file tree Collapse file tree 1 file changed +2
-0
lines changed Original file line number Diff line number Diff line change @@ -18,6 +18,7 @@ helm upgrade --install zilla $ZILLA_CHART --namespace $NAMESPACE --create-namesp
18
18
--set-file secrets.tls.data.localhost\\ .p12=../../tls/localhost.p12
19
19
20
20
# Create the mqtt topics in Kafka
21
+ if [[ " $KAFKA_SKIP_CREATE_TOPICS " != " yes" ]]; then
21
22
kubectl run kafka-init-pod --image=bitnami/kafka:3.2 --namespace $NAMESPACE --rm --restart=Never -i -t -- /bin/sh -c "
22
23
echo 'Creating topics for $KAFKA_HOST :$KAFKA_PORT '
23
24
/opt/bitnami/kafka/bin/kafka-topics.sh --bootstrap-server $KAFKA_HOST :$KAFKA_PORT --create --if-not-exists --topic mqtt-messages
@@ -26,6 +27,7 @@ echo 'Creating topics for $KAFKA_HOST:$KAFKA_PORT'
26
27
/opt/bitnami/kafka/bin/kafka-topics.sh --bootstrap-server $KAFKA_HOST :$KAFKA_PORT --create --if-not-exists --topic mqtt-sessions --config cleanup.policy=compact
27
28
"
28
29
kubectl wait --namespace $NAMESPACE --for=delete pod/kafka-init-pod
30
+ fi
29
31
30
32
# Start port forwarding
31
33
SERVICE_PORTS=$( kubectl get svc --namespace $NAMESPACE zilla --template " {{ range .spec.ports }}{{.port}} {{ end }}" )
You can’t perform that action at this time.
0 commit comments