autoconnect.no to import
This commit is contained in:
parent
a32cd0560a
commit
07d5ab0145
5
wire_g
5
wire_g
@ -99,14 +99,13 @@ import_wg(){
|
|||||||
then
|
then
|
||||||
wg_stop
|
wg_stop
|
||||||
nmcli connection import type wireguard file $WG_CONF &> ${WG_WDIR}.tmp.txt
|
nmcli connection import type wireguard file $WG_CONF &> ${WG_WDIR}.tmp.txt
|
||||||
nmcli con mod "$WG_CONF" connection.autoconnect no
|
|
||||||
wg_notify
|
wg_notify
|
||||||
else
|
else
|
||||||
kill $lines
|
kill $lines
|
||||||
nmcli connection import type wireguard file $WG_CONF &> ${WG_WDIR}.tmp.txt
|
nmcli connection import type wireguard file $WG_CONF &> ${WG_WDIR}.tmp.txt
|
||||||
nmcli con mod "$WG_CONF" connection.autoconnect no
|
|
||||||
wg_notify
|
wg_notify
|
||||||
fi
|
fi
|
||||||
|
nmcli con mod "$WG_CONF" connection.autoconnect no
|
||||||
nmcli connection show --active | grep -iPo "(.*)(wireguard)" | sed 's/ .*//' &> ${WG_WDIR}onstart.txt
|
nmcli connection show --active | grep -iPo "(.*)(wireguard)" | sed 's/ .*//' &> ${WG_WDIR}onstart.txt
|
||||||
fi ;;
|
fi ;;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user