improve cluster node compose and instructions

This commit is contained in:
Eduardo Silva
2026-11-23 11:19:29 -03:00
parent cb08b19a1d
commit e519ba666a
3 changed files with 64 additions and 16 deletions
+35 -2
View File
@@ -1,14 +1,45 @@
# App Gateway for cluster nodes. Use together with testing-cluster_node.yml:
# docker compose -f testing-cluster_node.yml -f testing-cluster_node-gateway.yml up -d
# Cluster node with WireGuard and the App Gateway (Caddy + auth-gateway).
# For a VPN only node, use cluster_node.yml instead.
services:
cluster-node:
container_name: cluster-node
restart: unless-stopped
image: eduardosilva/wireguard-webadmin-cluster-node:testing
environment:
- MASTER_SERVER_ADDRESS=${MASTER_SERVER_ADDRESS}
- COMPOSE_VERSION=c2a
- TZ=${TIMEZONE}
- TOKEN=${TOKEN}
volumes:
- cluster_node_wireguard:/etc/wireguard
- cluster_node_dnsmasq_conf:/etc/dnsmasq/
- cluster_node_caddy_json:/caddy_json_export/
- cluster_node_caddy_certificates:/caddy_certificates/
ports:
# Ports for WireGuard instances.
- "51820-51839:51820-51839/udp"
# Caddy shares the network of cluster-node, so its ports are published here
- "80:80"
- "443:443"
cap_add:
- NET_ADMIN
- SYS_MODULE
sysctls:
- net.ipv4.conf.all.src_valid_mark=1
- net.ipv4.ip_forward=1
cluster-node-dns:
container_name: cluster-node-dns
restart: unless-stopped
image: eduardosilva/wireguard_webadmin_dns:testing
# Shares the network of cluster-node, so DNS is answered directly on the WireGuard interfaces
network_mode: "service:cluster-node"
environment:
- TZ=${TIMEZONE}
volumes:
- cluster_node_dnsmasq_conf:/etc/dnsmasq/
depends_on:
- cluster-node
cluster-node-caddy:
container_name: cluster-node-caddy
@@ -41,6 +72,8 @@ services:
- cluster_node_auth_gateway_data:/data
volumes:
cluster_node_wireguard:
cluster_node_dnsmasq_conf:
cluster_node_caddy_json:
cluster_node_caddy_certificates:
cluster_node_caddy_data: