mirror of
https://github.com/gravitl/netmaker.git
synced 2024-11-10 17:48:25 +08:00
83 lines
2.2 KiB
YAML
83 lines
2.2 KiB
YAML
version: "3.4"
|
|
|
|
services:
|
|
netmaker:
|
|
container_name: netmaker
|
|
image: gravitl/netmaker:v0.14.3
|
|
volumes:
|
|
- dnsconfig:/root/config/dnsconfig
|
|
- sqldata:/root/data
|
|
- /root/certs:/etc/netmaker/
|
|
cap_add:
|
|
- NET_ADMIN
|
|
- NET_RAW
|
|
- SYS_MODULE
|
|
sysctls:
|
|
- net.ipv4.ip_forward=1
|
|
- net.ipv4.conf.all.src_valid_mark=1
|
|
- net.ipv6.conf.all.disable_ipv6=0
|
|
- net.ipv6.conf.all.forwarding=1
|
|
restart: always
|
|
environment:
|
|
SERVER_NAME: "broker.NETMAKER_BASE_DOMAIN"
|
|
SERVER_HOST: "SERVER_PUBLIC_IP"
|
|
SERVER_API_CONN_STRING: "api.NETMAKER_BASE_DOMAIN:443"
|
|
COREDNS_ADDR: "SERVER_PUBLIC_IP"
|
|
DNS_MODE: "off"
|
|
SERVER_HTTP_HOST: "api.NETMAKER_BASE_DOMAIN"
|
|
API_PORT: "8081"
|
|
CLIENT_MODE: "on"
|
|
MASTER_KEY: "REPLACE_MASTER_KEY"
|
|
CORS_ALLOWED_ORIGIN: "*"
|
|
DISPLAY_KEYS: "on"
|
|
DATABASE: "sqlite"
|
|
NODE_ID: "netmaker-server-1"
|
|
MQ_HOST: "mq"
|
|
HOST_NETWORK: "off"
|
|
VERBOSITY: "1"
|
|
MANAGE_IPTABLES: "on"
|
|
PORT_FORWARD_SERVICES: "dns"
|
|
ports:
|
|
- "51821-51830:51821-51830/udp"
|
|
- "8081:8081"
|
|
- "50051:50051"
|
|
netmaker-ui:
|
|
container_name: netmaker-ui
|
|
depends_on:
|
|
- netmaker
|
|
image: gravitl/netmaker-ui:v0.14.3
|
|
links:
|
|
- "netmaker:api"
|
|
ports:
|
|
- "8082:80"
|
|
environment:
|
|
BACKEND_URL: "https://api.NETMAKER_BASE_DOMAIN"
|
|
restart: always
|
|
caddy:
|
|
image: caddy:latest
|
|
container_name: caddy
|
|
restart: unless-stopped
|
|
network_mode: host # Wants ports 80 and 443!
|
|
volumes:
|
|
- /root/Caddyfile:/etc/caddy/Caddyfile
|
|
# - $PWD/site:/srv # you could also serve a static site in site folder
|
|
- caddy_data:/data
|
|
- caddy_conf:/config
|
|
mq:
|
|
image: eclipse-mosquitto:2.0.11-openssl
|
|
container_name: mq
|
|
restart: unless-stopped
|
|
ports:
|
|
- "127.0.0.1:1883:1883"
|
|
- "8883:8883"
|
|
volumes:
|
|
- /root/mosquitto.conf:/mosquitto/config/mosquitto.conf
|
|
- mosquitto_data:/mosquitto/data
|
|
- mosquitto_logs:/mosquitto/log
|
|
- /root/certs/:/mosquitto/certs/
|
|
volumes:
|
|
caddy_data: {}
|
|
caddy_conf: {}
|
|
sqldata: {}
|
|
mosquitto_data: {}
|
|
mosquitto_logs: {}
|