wireguard

Configures WireGuard VPN server.

Use it on boxctl

  1. On the dashboard, pick wireguard in the Template picker and click Boot box.
  2. The box boots, then runs wireguard/vpn.sh on itself. The button reads Booting… until the script has finished.
  3. Open the box's Terminal and follow the guide below. The box's row keeps a link back to this page under the template's name.

The guide is shared with the onctl CLI, so it starts from an onctl up -a wireguard/vpn.sh command. Booting a box with this template replaces that command; everything the guide runs on the VM itself applies as written.


Wireguard simple setup

Spin up a wireguard server with a single command.

onctl up -n wg -a wireguard/vpn.sh

For you mobile devices, install wireguard app and scan the qr code below.

http://<IP>/qr.png

For your desktop, use the following configuration.

http://<IP>/wg-client.conf

Wireguard with multiple clients

Set NUM_OF_CLIENTS parameter to number of clients you need.

onctl up -n wg-multi -a wireguard/multi.sh -e NUM_OF_CLIENTS=5

For you mobile devices, install wireguard app and scan the qr code below.

http://<IP>/qr-client1.png
http://<IP>/qr-client2.png
http://<IP>/qr-client3.png
http://<IP>/qr-client4.png
http://<IP>/qr-client5.png

For your desktop, use the following configuration.

http://<IP>/wg-client1.conf
http://<IP>/wg-client2.conf
http://<IP>/wg-client3.conf
http://<IP>/wg-client4.conf
http://<IP>/wg-client5.conf

See the template's source for exactly what it runs.