-o 1 --my=zero2:5080
This should be -o 1 --my=zero2:5081
also change the ports in the docker context. And here --zero=zero1:5080,zero2:5081,zero3:5082
Here too alpha --my=alpha3:7082
This whole docker compose looks wrong… where did you get it?
Not sure what it means.
Based in your yml. You have 3 zero nodes and 9 Alpha nodes. You have set the replica to 3.
Which means 3 shard groups. What is DC? Dgraph Cluster?
different Dgraph Clusters? really not sure what you mean.
Try this
ps. Just change my name to yours in the user path.
version: "3.2"
networks:
dg_net:
driver: bridge
ipam:
config:
- subnet: 10.5.0.0/16
gateway: 10.5.0.1
services:
zero1:
image: dgraph/dgraph:v22.0.2
volumes:
- /home/micheldiz/dgraph/zero1:/dgraph
ports:
- 5081:5080
- 6081:6080
restart: on-failure
networks:
dg_net:
ipv4_address: 10.5.0.21
healthcheck:
test: curl -sS http://localhost:6080/state | grep -o '10.5.0.21.*?*forceGroupId' | grep -c 'amDead":false' > /dev/null
interval: 10s
start_period: 10s
timeout: 5s
retries: 7
command: dgraph zero --my=10.5.0.21:5080 --replicas 3 --raft="idx=1"
zero2:
image: dgraph/dgraph:v22.0.2
volumes:
- /home/micheldiz/dgraph/zero2:/dgraph
ports:
- 5082:5080
- 6082:6080
restart: on-failure
networks:
dg_net:
ipv4_address: 10.5.0.22
healthcheck:
test: curl -sS http://localhost:6080/state | grep -o '10.5.0.22.*?*forceGroupId' | grep -c 'amDead":false' > /dev/null
interval: 10s
start_period: 10s
timeout: 5s
retries: 7
command: dgraph zero --my=10.5.0.22:5080 --replicas 3 --raft="idx=2" --peer 10.5.0.21:5080
zero3:
image: dgraph/dgraph:v22.0.2
volumes:
- /home/micheldiz/dgraph/zero3:/dgraph
ports:
- 5083:5080
- 6083:6080
restart: on-failure
networks:
dg_net:
ipv4_address: 10.5.0.23
healthcheck:
test: curl -sS http://localhost:6080/state | grep -o '10.5.0.23.*?*forceGroupId' | grep -c 'amDead":false' > /dev/null
interval: 10s
start_period: 10s
timeout: 5s
retries: 7
command: dgraph zero --my=10.5.0.23:5080 --replicas 3 --raft="idx=3" --peer 10.5.0.21:5080
alpha1:
image: dgraph/dgraph:v22.0.2
volumes:
- /home/micheldiz/dgraph/alpha1:/dgraph
ports:
- 8081:8080
- 9081:9080
restart: on-failure
networks:
dg_net:
ipv4_address: 10.5.0.11
healthcheck:
test: curl -sS http://localhost:8080/health | grep -c 'healthy' > /dev/null
interval: 10s
start_period: 10s
timeout: 5s
retries: 7
command: dgraph alpha --my=10.5.0.11:7080 --zero=10.5.0.21:5080,10.5.0.22:5080,10.5.0.23:5080
--security "whitelist=0.0.0.0/0"
alpha2:
image: dgraph/dgraph:v22.0.2
volumes:
- /home/micheldiz/dgraph/alpha2:/dgraph
ports:
- 8082:8080
- 9082:9080
restart: on-failure
networks:
dg_net:
ipv4_address: 10.5.0.12
healthcheck:
test: curl -sS http://localhost:8080/health | grep -c 'healthy' > /dev/null
interval: 10s
start_period: 10s
timeout: 5s
retries: 7
command: dgraph alpha --my=10.5.0.12:7080 --zero=10.5.0.21:5080,10.5.0.22:5080,10.5.0.23:5080
--security "whitelist=0.0.0.0/0"
alpha3:
image: dgraph/dgraph:v22.0.2
volumes:
- /home/micheldiz/dgraph/alpha3:/dgraph
ports:
- 8083:8080
- 9083:9080
restart: on-failure
networks:
dg_net:
ipv4_address: 10.5.0.13
healthcheck:
test: curl -sS http://localhost:8080/health | grep -c 'healthy' > /dev/null
interval: 10s
start_period: 10s
timeout: 5s
retries: 7
command: dgraph alpha --my=10.5.0.13:7080 --zero=10.5.0.21:5080,10.5.0.22:5080,10.5.0.23:5080
--security "whitelist=0.0.0.0/0"
alpha4:
image: dgraph/dgraph:v22.0.2
volumes:
- /home/micheldiz/dgraph/alpha4:/dgraph
ports:
- 8084:8080
- 9084:9080
restart: on-failure
networks:
dg_net:
ipv4_address: 10.5.0.14
healthcheck:
test: curl -sS http://localhost:8080/health | grep -c 'healthy' > /dev/null
interval: 10s
start_period: 10s
timeout: 5s
retries: 7
command: dgraph alpha --my=10.5.0.14:7080 --zero=10.5.0.21:5080,10.5.0.22:5080,10.5.0.23:5080
--security "whitelist=0.0.0.0/0"
alpha5:
image: dgraph/dgraph:v22.0.2
volumes:
- /home/micheldiz/dgraph/alpha5:/dgraph
ports:
- 8085:8080
- 9085:9080
restart: on-failure
networks:
dg_net:
ipv4_address: 10.5.0.15
healthcheck:
test: curl -sS http://localhost:8080/health | grep -c 'healthy' > /dev/null
interval: 10s
start_period: 10s
timeout: 5s
retries: 7
command: dgraph alpha --my=10.5.0.15:7080 --zero=10.5.0.21:5080,10.5.0.22:5080,10.5.0.23:5080
--security "whitelist=0.0.0.0/0"
alpha6:
image: dgraph/dgraph:v22.0.2
volumes:
- /home/micheldiz/dgraph/alpha6:/dgraph
ports:
- 8086:8080
- 9086:9080
restart: on-failure
networks:
dg_net:
ipv4_address: 10.5.0.16
healthcheck:
test: curl -sS http://localhost:8080/health | grep -c 'healthy' > /dev/null
interval: 10s
start_period: 10s
timeout: 5s
retries: 7
command: dgraph alpha --my=10.5.0.16:7080 --zero=10.5.0.21:5080,10.5.0.22:5080,10.5.0.23:5080
--security "whitelist=0.0.0.0/0"
alpha7:
image: dgraph/dgraph:v22.0.2
volumes:
- /home/micheldiz/dgraph/alpha7:/dgraph
ports:
- 8087:8080
- 9087:9080
restart: on-failure
networks:
dg_net:
ipv4_address: 10.5.0.17
healthcheck:
test: curl -sS http://localhost:8080/health | grep -c 'healthy' > /dev/null
interval: 10s
start_period: 10s
timeout: 5s
retries: 7
command: dgraph alpha --my=10.5.0.17:7080 --zero=10.5.0.21:5080,10.5.0.22:5080,10.5.0.23:5080
--security "whitelist=0.0.0.0/0"
alpha8:
image: dgraph/dgraph:v22.0.2
volumes:
- /home/micheldiz/dgraph/alpha8:/dgraph
ports:
- 8088:8080
- 9088:9080
restart: on-failure
networks:
dg_net:
ipv4_address: 10.5.0.18
healthcheck:
test: curl -sS http://localhost:8080/health | grep -c 'healthy' > /dev/null
interval: 10s
start_period: 10s
timeout: 5s
retries: 7
command: dgraph alpha --my=10.5.0.18:7080 --zero=10.5.0.21:5080,10.5.0.22:5080,10.5.0.23:5080
--security "whitelist=0.0.0.0/0"
alpha9:
image: dgraph/dgraph:v22.0.2
volumes:
- /home/micheldiz/dgraph/alpha8:/dgraph
ports:
- 8089:8080
- 9089:9080
restart: on-failure
networks:
dg_net:
ipv4_address: 10.5.0.19
healthcheck:
test: curl -sS http://localhost:8080/health | grep -c 'healthy' > /dev/null
interval: 10s
start_period: 10s
timeout: 5s
retries: 7
command: dgraph alpha --my=10.5.0.19:7080 --zero=10.5.0.21:5080,10.5.0.22:5080,10.5.0.23:5080
--security "whitelist=0.0.0.0/0"
ratel:
image: dgraph/ratel:latest
ports:
- 8000:8000
networks:
dg_net:
ipv4_address: 10.5.0.20
command: dgraph-ratel