Quote from: crpb on August 13, 2024, 08:58:23 PMDoes not seem to work as of OPNsense 24.7.8-amd64
For any lost soul...
If your Wireguard "Instance" Name is e.g. "CB"Code Select
/usr/local/opnsense/scripts/Wireguard/wg-service-control.php restart $(pluginctl -S wireguard |jq -r '.[]|select(.description|endswith("CB"))|.id')
sudo pkg install jq
Fatal error: Uncaught TypeError: flock(): Argument #1 ($stream) must be of type resource, bool given in /usr/local/opnsense/scripts/Wireguard/wg-service-control.php:243
Stack trace:
#0 /usr/local/opnsense/scripts/Wireguard/wg-service-control.php(243): flock(false, 2)
#1 {main}
thrown in /usr/local/opnsense/scripts/Wireguard/wg-service-control.php on line 243
:-\ :( :'(