[v2,2/2] update.sh: Stop|Start OpenVPN for update

Message ID 20200507104616.11573-2-ummeegge@ipfire.org
State Accepted
Commit 4728e44c512515a027fd730da25f4aa7f4e4211f
Headers
Series OpenVPN: Add to update and exclude |

Commit Message

ummeegge May 7, 2020, 10:46 a.m. UTC
  Signed-off-by: Erik Kapfer <ummeegge@ipfire.org>
---
 config/rootfiles/core/145/update.sh | 8 ++++++++
 1 file changed, 8 insertions(+)
  

Patch

diff --git a/config/rootfiles/core/145/update.sh b/config/rootfiles/core/145/update.sh
index 2571fa3b3..4b9468a49 100644
--- a/config/rootfiles/core/145/update.sh
+++ b/config/rootfiles/core/145/update.sh
@@ -48,6 +48,10 @@  done
 # Stop services
 /etc/init.d/vnstat stop
 
+# Prepare OpenVPN for update
+/usr/local/bin/openvpnctrl -k
+/usr/local/bin/openvpnctrl -kn2n
+
 # Extract files
 extract_files
 
@@ -57,6 +61,10 @@  ldconfig
 # Start services
 /etc/init.d/vnstat start
 
+# Start OpenVPN again
+/usr/local/bin/openvpnctrl -s
+/usr/local/bin/openvpnctrl -sn2n
+
 # Update Language cache
 /usr/local/bin/update-lang-cache