Verbesserungen & Korrekturen aus rest-producer übernommen
[demos/kafka/training] / docker-compose.yml
index 175eed5..a6905a5 100644 (file)
@@ -34,6 +34,8 @@ services:
       KAFKA_CFG_AUTO_CREATE_TOPICS_ENABLE: "false"
     ports:
       - 9081:9081
+    depends_on:
+      - kafka-0
 
   kafka-2:
     image: bitnami/kafka:3.3.1
@@ -58,6 +60,8 @@ services:
       default:
         aliases:
           - kafka
+    depends_on:
+      - kafka-0
 
   kafka-3:
     image: bitnami/kafka:3.3.1
@@ -77,6 +81,9 @@ services:
       KAFKA_CFG_AUTO_CREATE_TOPICS_ENABLE: "false"
     ports:
       - 9083:9083
+    depends_on:
+      - kafka-0
+
 
   setup:
     image: juplo/toolbox
@@ -86,10 +93,18 @@ services:
         kafka-topics --bootstrap-server kafka:9092 --create --topic test --partitions 2 --replication-factor 3 --config min.insync.replicas=2
         kafka-topics --bootstrap-server kafka:9092 --describe --topic test
       "
+    depends_on:
+      - kafka-1
+      - kafka-2
+      - kafka-3
 
   cli:
     image: juplo/toolbox
     command: sleep infinity
+    depends_on:
+      - kafka-1
+      - kafka-2
+      - kafka-3
 
   producer:
     image: juplo/rest-producer-json:1.0-SNAPSHOT
@@ -124,5 +139,5 @@ services:
       "
 
   consumer:
-    image: juplo/toolbox
-    command: kafkacat -C -b kafka:9092 -t test -o 0 -f'p=%p|o=%o|k=%k|v=%s\n'
+    image: juplo/simple-consumer:1.0-SNAPSHOT
+    command: kafka:9092 test my-group consumer