64 lines
1.3 KiB
YAML
64 lines
1.3 KiB
YAML
services:
|
|
dns:
|
|
build:
|
|
context: .
|
|
dockerfile: ./docker/dnsmasq.Dockerfile
|
|
restart: always
|
|
depends_on:
|
|
- polyculenetwork1
|
|
volumes:
|
|
- "./config/dnsmasq.conf:/etc/dnsmasq.conf"
|
|
|
|
|
|
polyculenetwork1:
|
|
build:
|
|
context: .
|
|
dockerfile: ./docker/Dockerfile
|
|
container_name: polyculenetwork1
|
|
volumes:
|
|
- "./config:/config"
|
|
environment:
|
|
- LOCAL_NETWORK=net1
|
|
- PRIVATE_KEY=YLxXnAcelMMkanrdSHuci9ZSJyKQpRn7PdJK96IllV4=
|
|
- LISTEN_PORT=51820
|
|
cap_add:
|
|
- NET_ADMIN
|
|
sysctls:
|
|
net.ipv4.ip_forward: 1
|
|
networks:
|
|
net1:
|
|
ipv4_address: 172.20.1.11
|
|
internet:
|
|
ipv4_address: 172.20.0.11
|
|
|
|
polyculenetwork2:
|
|
build:
|
|
context: .
|
|
dockerfile: ./docker/Dockerfile
|
|
container_name: polyculenetwork2
|
|
volumes:
|
|
- "./config:/config"
|
|
environment:
|
|
- LOCAL_NETWORK=net2
|
|
- PRIVATE_KEY=OCllQNCxX5DxcJSEsjkvsWCry1FOnWe+aCupwEByFmk=
|
|
cap_add:
|
|
- NET_ADMIN
|
|
networks:
|
|
net2:
|
|
ipv4_address: 172.20.2.12
|
|
internet:
|
|
ipv4_address: 172.20.0.12
|
|
|
|
networks:
|
|
net1:
|
|
ipam:
|
|
config:
|
|
- subnet: 172.20.1.0/24
|
|
net2:
|
|
ipam:
|
|
config:
|
|
- subnet: 172.20.2.0/24
|
|
internet:
|
|
ipam:
|
|
config:
|
|
- subnet: 172.20.0.0/24
|