forked from IAmStoxe/wirehole
-
Notifications
You must be signed in to change notification settings - Fork 8
/
docker-compose.yml
83 lines (77 loc) · 2.08 KB
/
docker-compose.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
version: "3"
networks:
private_network:
ipam:
driver: default
config:
- subnet: 10.2.0.0/24
services:
unbound:
image: mvance/unbound:latest
container_name: unbound
restart: unless-stopped
hostname: unbound
networks:
private_network:
ipv4_address: 10.2.0.200
pihole:
depends_on:
- unbound
container_name: pihole
image: pihole/pihole:2023.10.0
hostname: pihole
restart: unless-stopped
dns:
- 127.0.0.1
- 10.2.0.200 # Points to unbound
environment:
TZ: "Europe/Istanbul"
WEBPASSWORD: ${PIHOLE_PASSWORD} # Blank password - Can be whatever you want.
ServerIP: 10.2.0.100 # Internal IP of pihole
DNS1: 10.2.0.200 # Unbound IP
DNS2: 10.2.0.200 # If we don't specify two, it will auto pick google.
# Volumes store your data between container upgrades
volumes:
- "./etc-pihole/:/etc/pihole/"
- "./etc-dnsmasq.d/:/etc/dnsmasq.d/"
# Recommended but not required (DHCP needs NET_ADMIN)
# https://github.com/pi-hole/docker-pi-hole#note-on-capabilities
cap_add:
- NET_ADMIN
networks:
private_network:
ipv4_address: 10.2.0.100
wg-easy:
depends_on:
- unbound
- pihole
environment:
# ⚠️ Required:
# Change this to your host's public address
- WG_HOST=${MASTER}
# Optional:
- PASSWORD=${WG_PASSWORD}
- WG_PORT=51820
- WG_DEFAULT_ADDRESS=10.3.0.x
- WG_DEFAULT_DNS=10.2.0.100
# - WG_ALLOWED_IPS=192.168.0.0/24,10.2.0.0/24,10.3.0.0/24 # If you want only LAN access open this.
image: weejewel/wg-easy:7
container_name: wg-easy
volumes:
- ./wg_confs/:/etc/wireguard
ports:
- "51820:51820/udp"
- "51821:51821/tcp"
restart: unless-stopped
cap_add:
- NET_ADMIN
- SYS_MODULE
sysctls:
- net.ipv4.ip_forward=1
- net.ipv4.conf.all.src_valid_mark=1
dns:
- 10.2.0.100 # Points to pihole
- 10.2.0.200 # Points to unbound
networks:
private_network:
ipv4_address: 10.2.0.3