Last active
August 27, 2021 18:18
-
-
Save randy3k/d54ee474f6e83ce7a1361e057471ae29 to your computer and use it in GitHub Desktop.
docker compose file for wireguard
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# to show qr | |
# docker exec -it wireguard /app/show-peer 1 | |
version: "2.1" | |
services: | |
wireguard: | |
image: linuxserver/wireguard | |
container_name: wireguard | |
cap_add: | |
- NET_ADMIN | |
- SYS_MODULE | |
environment: | |
- PUID=1000 | |
- PGID=1000 | |
- TZ=America/Los_Angeles | |
- SERVERPORT=51820 #optional | |
- PEERS=1 #optional | |
- PEERDNS=192.168.0.1 | |
- INTERNAL_SUBNET=10.13.13.0 #optional | |
- ALLOWEDIPS=192.168.0.1/24, 10.13.13.0/24 | |
volumes: | |
- /home/pi/wireguard/config:/config | |
- /lib/modules:/lib/modules | |
ports: | |
- 51820:51820/udp | |
sysctls: | |
- net.ipv4.conf.all.src_valid_mark=1 | |
restart: always |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment