From 3f9f2e3ea30850e45a496c8b6d65452b07e818ea Mon Sep 17 00:00:00 2001 From: Alexandre <44178713+alexbelgium@users.noreply.github.com> Date: Tue, 3 May 2022 13:47:31 +0200 Subject: [PATCH] Update 93-openvpn.sh --- qbittorrent/rootfs/etc/cont-init.d/93-openvpn.sh | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/qbittorrent/rootfs/etc/cont-init.d/93-openvpn.sh b/qbittorrent/rootfs/etc/cont-init.d/93-openvpn.sh index d58bd1d97..bb4c2cd11 100644 --- a/qbittorrent/rootfs/etc/cont-init.d/93-openvpn.sh +++ b/qbittorrent/rootfs/etc/cont-init.d/93-openvpn.sh @@ -94,11 +94,10 @@ if bashio::config.true 'openvpn_enabled'; then fi # Modify ovpn config - sed -i 's|exec /usr/sbin/openvpn |exec /usr/sbin/openvpn --route-nopull |g' /etc/services.d/qbittorrent/run - #if ! grep -q route-nopull /etc/openvpn/config.ovpn; then - # echo "... adding route-nopull to your config.ovpn" - # echo "route-nopull" >>/etc/openvpn/config.ovpn - #fi + if ! grep -q route-nopull /etc/openvpn/config.ovpn; then + echo "... adding route-nopull to your config.ovpn" + sed -i "1a route-nopull" /etc/openvpn/config.ovpn + fi else