No description
- Shell 100%
| install.sh | ||
| README.md | ||
debian-wireguard
INSTALLATION
curl -sfL https://yw5n.com/wg | sudo sh -
OPTIONAL VARIABLES
- SSHPORT: port on which to run sshd (if set, enables sshd)
- WGPORT (51820): port on which to run wireguard
ADD PEER
On the client:
privkey=$(wg genkey)
pubkey=$(wg pubkey <<< "$privkey")
cat <<EOF > /etc/wireguard/wg0.conf
[Interface]
PrivateKey = $(wg genkey)
Address = 10.0.0.2/32,fc00::2/128
[Peer]
PublicKey =
AllowedIPs = 0.0.0.0/0,::/0
Endpoint =
EOF
On the server
# devname
[Peer]
PublicKey = $(printf %s "$PRIVKEY" | wg pubkey)
AllowedIPs = 10.0.0.2/32,fc00:2/128