Created
November 25, 2022 08:58
-
-
Save marvell/a447802d0caa620fb0353b0ce94771f0 to your computer and use it in GitHub Desktop.
wg-easy setup
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
#!/bin/bash | |
curl -fsSL https://get.docker.com | sh | |
docker run -d \ | |
--name=wg-easy \ | |
-e WG_HOST=$(curl -sL4 https://ifconfig.io) \ | |
-e WG_PERSISTENT_KEEPALIVE=25 \ | |
-e WG_DEFAULT_ADDRESS=192.168.210.x \ | |
-v /etc/wg-easy:/etc/wireguard \ | |
-p 51820:51820/udp \ | |
-p 127.0.0.1:8000:51821/tcp \ | |
--cap-add=NET_ADMIN \ | |
--cap-add=SYS_MODULE \ | |
--sysctl="net.ipv4.conf.all.src_valid_mark=1" \ | |
--sysctl="net.ipv4.ip_forward=1" \ | |
--restart unless-stopped \ | |
weejewel/wg-easy |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Run on server:
curl -sL https://raw.githubusercontent.com/marvell/quick-vpn/main/setup.sh | sudo sh
. To access UI:ssh -L 8000:localhost:8000 <user>@<host>
.