This repository has been archived by the owner on Dec 31, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose-private.yml
83 lines (78 loc) · 2.03 KB
/
docker-compose-private.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.9"
volumes:
pihole-volume:
name: pihole
dnsmasq.d-volume:
name: pihole-dnsmasq.d
wireguard-private-volume:
name: wireguard-private-config
networks:
private-network:
name: pwn-private
ipam:
driver: default
config:
- subnet: 10.2.0.0/24
services:
unbound:
image: "mvance/unbound:latest"
container_name: unbound
restart: unless-stopped
hostname: "unbound"
volumes:
- "./unbound:/opt/unbound/etc/unbound/"
networks:
private-network:
ipv4_address: 10.2.0.200
wireguard-private:
depends_on: [unbound, pihole]
image: linuxserver/wireguard
container_name: wireguard-private
cap_add:
- NET_ADMIN
- SYS_MODULE
environment:
- PUID=1000
- PGID=1000
- TZ=America/New_York # Change to your timezone.
- SERVERPORT=50000
- PEERS=1 # Number of Client profiles (Change change this in portainer)
- PEERDNS=10.2.0.100 # points to Pihole
- INTERNAL_SUBNET=10.6.0.0 # Subnet for all wireguard connections.
- ALLOWEDIPS=10.6.0.0/24, 10.2.0.0/24 # To tunnel all network, remove this line.'
volumes:
- wireguard-private-volume:/config
- /lib/modules:/lib/modules
ports:
- "50000:51820/udp"
dns:
- 10.2.0.100 # points to Pihole
- 10.2.0.200 # points to Unbound
sysctls:
- net.ipv4.conf.all.src_valid_mark=1
restart: unless-stopped
networks:
private-network:
ipv4_address: 10.2.0.3
pihole:
depends_on: [unbound]
container_name: pihole
image: pihole/pihole:latest
restart: unless-stopped
hostname: pihole
dns:
- 127.0.0.1
- 10.2.0.200 # points to Unbound
environment:
TZ: "America/New_York"
WEBPASSWORD: ""
ServerIP: 10.1.0.100
PIHOLE_DNS_: 10.2.0.200;10.2.0.200 # points to Unbound
volumes:
- pihole-volume/:/etc/pihole/
- dnsmasq.d-volume/:/etc/dnsmasq.d/
cap_add:
- NET_ADMIN
networks:
private-network:
ipv4_address: 10.2.0.100