Last active
September 21, 2023 23:13
-
-
Save rgaidot/001b74333943abc5ad215f03b054246d to your computer and use it in GitHub Desktop.
wireguard with wireguard-ui
This file contains hidden or 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
version: "3" | |
services: | |
wireguard: | |
image: linuxserver/wireguard:latest | |
container_name: wireguard | |
cap_add: | |
- NET_ADMIN | |
sysctls: | |
- net.ipv4.conf.all.src_valid_mark=1 | |
- net.ipv6.conf.all.disable_ipv6=1 | |
- net.ipv6.conf.default.disable_ipv6=1 | |
environment: | |
- SERVERURL=wireguard.domain.com # change me | |
- ALLOWEDIPS=0.0.0.0/0,::0/0 | |
- PEERS=5 # optional | |
- LOG_CONFS=false | |
- PEERDNS=auto | |
volumes: | |
- ./config:/config | |
- /lib/modules:/lib/modules | |
ports: | |
- "51830:5000" | |
- "51820:51820/udp" | |
wireguard-ui: | |
image: ngoduykhanh/wireguard-ui:latest | |
container_name: wireguard-ui | |
depends_on: | |
- wireguard | |
cap_add: | |
- NET_ADMIN | |
network_mode: service:wireguard | |
environment: | |
- WGUI_USERNAME=admin # change me | |
- WGUI_PASSWORD=password # change me | |
- WGUI_MANAGE_START=true | |
- WGUI_MANAGE_RESTART=true | |
logging: | |
driver: json-file | |
options: | |
max-size: 50m | |
volumes: | |
- ./db:/app/db | |
- ./config:/etc/wireguard |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment