Some lovely wholesome developer has included: connmanctl.
Which really makes it easy to setup a wireguard vpn.
And has its own config system, just create a:
nano myvpn.config in that directory.
[provider_wireguard] Type = WireGuard Name = VPNNAME Host = (The IP of the VPN Server. Ping its hostname) Domain = ThisMustHaveANameAndByGawdANYNAME WireGuard.Address = The VPN internal server IP (ends with 24 or 32 usually)/32 WireGuard.PrivateKey = yourPrivateKeyHere WireGuard.PublicKey = yourPublickeyThere WireGuard.DNS = DNS_IP1, DNS_IP2 WireGuard.AllowedIPs = 0.0.0.0/0 WireGuard.EndpointPort = TheServerPort WireGuard.PersistentKeepalive = 25
(There shall be no () in the config!)
Then you save it.
connmanctl whack enter.
Now you should be able to see it by typing:
services (and whack enter)
If everything is ok, it should be listed.
Now you can type:
connect (first letter of config & press TAB)
Likewise, you type
disconnect to disconnect.
And then it should say:
quit to Quit.
You can check your external ip by:
nslookup myip.opendns.com resolver1.opendns.com
If you wish, you can setup so that it starts on boot by:
config VPNNAMEByTAB autoconnect yes
Enable the service:
systemctl enable connman
Now, I hope to use my N2 as a gateway (see thread), so that the local network can use wireguard at the same time. Seems to be iptables that’s missing.