56 lines
1.3 KiB
YAML
56 lines
1.3 KiB
YAML
version: '3.4'
|
|
|
|
networks:
|
|
firstsubnet:
|
|
driver: bridge
|
|
ipam:
|
|
driver: default
|
|
config:
|
|
- subnet: 192.168.1.0/24
|
|
|
|
services:
|
|
producer1:
|
|
restart: unless-stopped
|
|
image: tormachris/p2p-producer
|
|
networks:
|
|
firstsubnet:
|
|
ipv4_address: 192.168.1.11
|
|
producer2:
|
|
restart: unless-stopped
|
|
image: tormachris/p2p-producer
|
|
networks:
|
|
firstsubnet:
|
|
ipv4_address: 192.168.1.12
|
|
|
|
consumer1:
|
|
restart: unless-stopped
|
|
image: tormachris/p2p-consumer
|
|
environment:
|
|
- REDIS_URL=192.168.1.31
|
|
networks:
|
|
firstsubnet:
|
|
ipv4_address: 192.168.1.21
|
|
consumer2:
|
|
restart: unless-stopped
|
|
image: tormachris/p2p-consumer
|
|
environment:
|
|
- REDIS_URL=192.168.1.32
|
|
|
|
networks:
|
|
firstsubnet:
|
|
ipv4_address: 192.168.1.22
|
|
|
|
redis1:
|
|
image: redis
|
|
restart: unless-stopped
|
|
networks:
|
|
firstsubnet:
|
|
ipv4_address: 192.168.1.31
|
|
|
|
redis2:
|
|
image: redis
|
|
restart: unless-stopped
|
|
networks:
|
|
firstsubnet:
|
|
ipv4_address: 192.168.1.32
|