#!/bin/sh usage() { echo "Usage: vpn-client.sh " echo "hostname: Name of the new host" exit 1 } if [ $# != 1 ]; then usage fi hostname=$1 wg genkey | tee "$hostname".key | wg pubkey >"$hostname".pub