2023-04-13 01:13:24 +00:00
|
|
|
services:
|
|
|
|
rp1:
|
|
|
|
image: docker.redpanda.com/vectorized/redpanda:v22.2.2
|
|
|
|
restart: on-failure:10
|
|
|
|
ports:
|
|
|
|
- 9092:9092
|
|
|
|
command:
|
|
|
|
- redpanda start
|
|
|
|
- --smp 1
|
|
|
|
- --memory 1G
|
|
|
|
- --reserve-memory 0M
|
|
|
|
- --overprovisioned
|
|
|
|
- --node-id 0
|
|
|
|
- --check=false
|
|
|
|
- --pandaproxy-addr PLAINTEXT://0.0.0.0:28082,OUTSIDE://0.0.0.0:8082
|
|
|
|
- --advertise-pandaproxy-addr PLAINTEXT://rp1:28082,OUTSIDE://rp1:8082
|
|
|
|
- --kafka-addr PLAINTEXT://0.0.0.0:29092,OUTSIDE://0.0.0.0:9092
|
|
|
|
- --advertise-kafka-addr PLAINTEXT://rp1:29092,OUTSIDE://rp1:9092
|
|
|
|
- --rpc-addr 0.0.0.0:33145
|
|
|
|
- --advertise-rpc-addr rp1:33145
|
|
|
|
volumes:
|
|
|
|
- rp1data:/var/lib/redpanda/data
|
|
|
|
healthcheck:
|
|
|
|
test: [ "CMD", "rpk", "cluster", "health" ]
|
|
|
|
interval: 30s
|
|
|
|
timeout: 5s
|
|
|
|
retries: 3
|
2023-04-15 12:22:21 +00:00
|
|
|
start_period: 60s
|
2023-04-13 01:13:24 +00:00
|
|
|
|
|
|
|
rp2:
|
|
|
|
image: docker.redpanda.com/vectorized/redpanda:v22.2.2
|
|
|
|
restart: on-failure:10
|
|
|
|
ports:
|
|
|
|
- 9093:9092
|
|
|
|
command:
|
|
|
|
- redpanda start
|
|
|
|
- --smp 1
|
|
|
|
- --memory 1G
|
|
|
|
- --reserve-memory 0M
|
|
|
|
- --overprovisioned
|
2023-04-15 12:22:21 +00:00
|
|
|
- --node-id 1
|
2023-04-13 01:13:24 +00:00
|
|
|
- --check=false
|
|
|
|
- --pandaproxy-addr PLAINTEXT://0.0.0.0:28082,OUTSIDE://0.0.0.0:8082
|
|
|
|
- --advertise-pandaproxy-addr PLAINTEXT://rp2:28082,OUTSIDE://rp2:8082
|
|
|
|
- --kafka-addr PLAINTEXT://0.0.0.0:29092,OUTSIDE://0.0.0.0:9092
|
|
|
|
- --advertise-kafka-addr PLAINTEXT://rp2:29092,OUTSIDE://rp2:9092
|
|
|
|
- --rpc-addr 0.0.0.0:33145
|
|
|
|
- --advertise-rpc-addr rp2:33145
|
|
|
|
- --seeds rp1:33145
|
|
|
|
volumes:
|
|
|
|
- rp2data:/var/lib/redpanda/data
|
|
|
|
healthcheck:
|
|
|
|
test: [ "CMD", "rpk", "cluster", "health" ]
|
|
|
|
interval: 30s
|
|
|
|
timeout: 5s
|
|
|
|
retries: 3
|
2023-04-15 12:22:21 +00:00
|
|
|
start_period: 60s
|
2023-04-13 01:13:24 +00:00
|
|
|
depends_on:
|
|
|
|
rp1:
|
|
|
|
condition: service_healthy
|
|
|
|
|
|
|
|
rp3:
|
|
|
|
image: docker.redpanda.com/vectorized/redpanda:v22.2.2
|
|
|
|
restart: on-failure:10
|
|
|
|
ports:
|
|
|
|
- 9094:9092
|
|
|
|
command:
|
|
|
|
- redpanda start
|
|
|
|
- --smp 1
|
|
|
|
- --memory 1G
|
|
|
|
- --reserve-memory 0M
|
|
|
|
- --overprovisioned
|
2023-04-15 12:22:21 +00:00
|
|
|
- --node-id 2
|
2023-04-13 01:13:24 +00:00
|
|
|
- --check=false
|
|
|
|
- --pandaproxy-addr PLAINTEXT://0.0.0.0:28082,OUTSIDE://0.0.0.0:8082
|
|
|
|
- --advertise-pandaproxy-addr PLAINTEXT://rp3:28082,OUTSIDE://rp3:8082
|
|
|
|
- --kafka-addr PLAINTEXT://0.0.0.0:29092,OUTSIDE://0.0.0.0:9092
|
|
|
|
- --advertise-kafka-addr PLAINTEXT://rp3:29092,OUTSIDE://rp3:9092
|
|
|
|
- --rpc-addr 0.0.0.0:33145
|
|
|
|
- --advertise-rpc-addr rp3:33145
|
|
|
|
- --seeds rp1:33145,rp2:33145
|
|
|
|
volumes:
|
|
|
|
- rp3data:/var/lib/redpanda/data
|
|
|
|
healthcheck:
|
|
|
|
test: [ "CMD", "rpk", "cluster", "health" ]
|
|
|
|
interval: 30s
|
|
|
|
timeout: 5s
|
|
|
|
retries: 3
|
2023-04-15 12:22:21 +00:00
|
|
|
start_period: 60s
|
2023-04-13 01:13:24 +00:00
|
|
|
depends_on:
|
|
|
|
rp1:
|
|
|
|
condition: service_healthy
|
|
|
|
|
|
|
|
# This is for viewing the Redpanda topics and the contents within it.
|
|
|
|
kafka-console:
|
|
|
|
image: docker.redpanda.com/vectorized/console:latest
|
|
|
|
environment:
|
2023-04-15 12:22:21 +00:00
|
|
|
KAFKA_BROKERS: rp1:9092,rp2:9092,rp3:9092
|
2023-04-13 01:13:24 +00:00
|
|
|
ports:
|
|
|
|
- 8080:8080
|
|
|
|
depends_on:
|
2023-04-15 12:22:21 +00:00
|
|
|
rp1:
|
|
|
|
condition: service_healthy
|
|
|
|
rp2:
|
|
|
|
condition: service_healthy
|
|
|
|
rp3:
|
|
|
|
condition: service_healthy
|
|
|
|
|
|
|
|
volumes:
|
|
|
|
rp1data:
|
|
|
|
rp2data:
|
|
|
|
rp3data:
|