mirror of
https://github.com/Ysurac/openmptcprouter-feeds.git
synced 2025-03-09 15:40:03 +00:00
Restart OpenVPN only if not started and with a CA
This commit is contained in:
parent
8ec0bdff9b
commit
6dbc29ae7b
1 changed files with 1 additions and 1 deletions
|
@ -42,7 +42,7 @@ fi
|
|||
if [ "$(pgrep openvpn)" = "" ] && [ -f /etc/init.d/openvpn ]; then
|
||||
openvpn_enable=0
|
||||
openvpn_enabled() {
|
||||
[ "$(uci -q get openvpn.$1.enabled)" = "1" ] && openvpn_enable=1
|
||||
[ "$(uci -q get openvpn.$1.enabled)" = "1" ] && [ -n "$(uci -q get openvpn.$1.ca)" ] && openvpn_enable=1
|
||||
}
|
||||
config_load openvpn
|
||||
config_foreach openvpn_enabled openvpn
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue