From 9a27865acbcd08acc703d0e9412a6fe93c12d4b6 Mon Sep 17 00:00:00 2001 From: Florian Eckert Date: Wed, 20 Dec 2023 10:19:24 +0100 Subject: [PATCH] openvpn: add possibility to start openvpn_path_instance on request This commit adds the possibility that an OpenVPN instance located under '/etc/openvpn' can also be started with the command. '/etc/init.d/openvpn start ' Signed-off-by: Florian Eckert --- net/openvpn/files/openvpn.init | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/net/openvpn/files/openvpn.init b/net/openvpn/files/openvpn.init index 791018cc4b..806afe2753 100644 --- a/net/openvpn/files/openvpn.init +++ b/net/openvpn/files/openvpn.init @@ -263,8 +263,11 @@ start_service() { config_load 'openvpn' if [ -n "$instance" ]; then - [ "$instance_found" -gt 0 ] || return - start_uci_instance "$instance" + if [ "$instance_found" -gt 0 ]; then + start_uci_instance "$instance" + else + start_path_instance "$instance" + fi else config_foreach start_uci_instance 'openvpn' -- 2.30.2