- Install wireguard if required.
wg genkey | tee wgprivatekey | wg pubkey > wgpublickey
- note your private key is along with the public key in the folder you just executed the above commands in.
- grab the generated privatekey and put it at the logical place with the rest of this config in
/etc/wireguard/someinterface.conf
[Interface]
PrivateKey = PRIVKEYHERE
ListenPort = SOMEPORT
Address = LOCALVPNADDRESS/SUBNET