aboutsummaryrefslogtreecommitdiffstats
path: root/roles/workstation/templates/_openbsd/apm-resume
blob: 18397b42475f312aa4179a6065da08f1938fe1c0 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#!/bin/sh

set -x -e

sleep 3

sh /etc/netstart iwn0

wg_interfaces=$(find /etc/wireguard -type f | sed 's/\.conf$//g')
for wg_interface in ${wg_interfaces}; do
	wg_interface=$(basename "${wg_interface}")
	wg-quick down "${wg_interface}"
	wg-quick up "${wg_interface}"
done

rcctl -d restart pcscd
remember that computers suck.