内网建设,利用服务器+WireGuard建立异地局域网

代码 · 2023-09-27 · 166 人浏览

https://www.bilibili.com/video/BV1uT411w7Tq/

docker run -d \
  --name=wg-easy \
  -e WG_HOST=YourIpAddress \
  -e PASSWORD=YourIpPassword \
  -e WG_DEFAULT_ADDRESS=10.0.8.x \
  -e WG_DEFAULT_DNS=114.114.114.114 \
  -e WG_ALLOWED_IPS=10.0.8.0/24 \
  -e WG_PERSISTENT_KEEPALIVE=25 \
  -v ~/.wg-easy:/etc/wireguard \
  -p 51820:51820/udp \
  -p 51821: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

群晖 WireGuard
https://www.bilibili.com/read/cv18452418/

Theme Jasmine by Kent Liao