WireGuard for homelabs, servers and Proxmox
Connect your Linux machines over WireGuard, from one file.
List your machines in wglink.yaml, preview the change with wglink plan, and make it with wglink apply. Private keys are made on the machines that use them and never leave.
One static binary · no agent · no server · no account · MIT
$ wglink connect pve1 nas pi --name lab Network lab: pve1, nas, pi. $ wglink plan network lab wg-lab 10.99.0.0/24 udp/51820 + pve1 10.99.0.1 new interface, 2 peers, new key + nas 10.99.0.2 new interface, 2 peers, new key + pi 10.99.0.3 new interface, 2 peers, new key 3 to create, 0 to change live, 0 to restart, 0 to remove. $ wglink apply --yes && wglink status pve1 <-> nas ok handshake 14s ago, ping 0.4 ms pve1 <-> pi ok idle, ping 1.1 ms nas <-> pi ok handshake 1m ago, ping 0.9 ms All 3 links are ok.
Infrastructure habits, for your tunnels.
What wglink leaves behind are ordinary wg-quick configs that keep working without it.
wglink plan
Plan before you apply
Every change is previewed. Peer changes load live with wg syncconf; address, port and MTU changes restart the interface.
wg genkey, on the node
Keys stay home
Each private key is made on the machine that uses it, and only public keys come back. Rotate them with one command, and add a preshared key for each pair.
revert timer
Safe changes over SSH
A change that cuts wglink off from a node is undone by the node itself a minute later, unless wglink confirms it over a fresh connection.
wglink discover pve1
Made for Proxmox
List a host's containers and VMs and add them as nodes. Guests are reached through the host, so they need no SSH.
--hub · routes · --ipv6
Any shape of network
Full mesh or hub-and-spoke, subnets routed through a member, IPv6 inside the tunnels, and phones set up with wglink export.
wglink status --json
Health at a glance
Every link is judged from handshakes and pings through the tunnel, with JSON for scripts and exit codes for monitoring.
How it works
No agent: small shell scripts, embedded in the binary, run over the connections you already use.
- ProbeRead-only scripts report addresses, routes, ports and WireGuard configs, private keys removed.
- ResolvePinned values first, then ones recorded earlier, then new picks that avoid everything in use.
- DiffEach config is rendered and compared with the node's; hand edits show up as drift.
- ApplyConfigs travel without private keys; each node inserts its own and loads the change.
- ConfirmA fresh SSH connection cancels the node's revert timer, or the node undoes the change.
A dashboard in your terminal
wglink ui shows every network and the health of its links, checked again every 10 seconds.
Add a node, connect it, review the plan and apply it, without leaving the screen.
wglink ~/infra/wglink.yaml checked 12:04:05 NETWORKS network lab wg-lab 10.99.0.0/24 udp/51820 ✓ lab 3/3 pve1 10.99.0.1 up ✗ road 0/1 nas 10.99.0.2 up vps 10.99.0.3 up pve1 <-> nas ok rx 45.8 MiB tx 3.0 MiB pve1 <-> vps ok rx 2.1 MiB tx 9.3 MiB nas <-> vps ok rx 878.9 KiB tx 1.1 MiB ↑/↓ network · p plan · c connect nodes · n new node · q quit
Built to be trusted with root
wglink runs as root on your machines, so it keeps its footprint small and its secrets where they belong.
- Private keys never travelConfigs are sent without them, and each node fills in its own key as it writes the file.
- No secrets on the controllerThe state file holds public keys, addresses and hashes. Preshared keys are compared by hash.
- Nothing to inject intoScripts go to
shover stdin; their only inputs are a few validated, quoted variables. - Tested on real WireGuardCI builds networks in Linux namespaces, and fails if a key ever shows up in a script's output.
Install
Packages for Debian, Ubuntu, Fedora and RHEL install shell completions and recommend wireguard-tools. Everything is built for Linux on amd64, arm64 and armv7.
VERSION=0.4.0 ARCH=amd64 # or arm64, armhf
curl -fsSLO "https://github.com/gureetk/wglink/releases/download/v$VERSION/wglink_${VERSION}-1_$ARCH.deb"
sudo apt install "./wglink_${VERSION}-1_$ARCH.deb"VERSION=0.4.0 ARCH=x86_64 # or aarch64, armv7hl
curl -fsSLO "https://github.com/gureetk/wglink/releases/download/v$VERSION/wglink-$VERSION-1.$ARCH.rpm"
sudo dnf install "./wglink-$VERSION-1.$ARCH.rpm"VERSION=0.4.0 ARCH=amd64 # or arm64, armv7
curl -fsSLO "https://github.com/gureetk/wglink/releases/download/v$VERSION/wglink_${VERSION}_linux_$ARCH.tar.gz"
curl -fsSLO "https://github.com/gureetk/wglink/releases/download/v$VERSION/SHA256SUMS"
sha256sum --check --ignore-missing SHA256SUMS
tar -xzf "wglink_${VERSION}_linux_$ARCH.tar.gz"
sudo install "wglink_${VERSION}_linux_$ARCH/wglink" /usr/local/bin/# Go 1.26 or newer
go install github.com/gureetk/wglink/cmd/wglink@latest