From a71d98590a21d84fbca51078a0f7085f0bcecb84 Mon Sep 17 00:00:00 2001 From: Alexandre <44178713+alexbelgium@users.noreply.github.com> Date: Thu, 14 Dec 2023 10:07:24 +0100 Subject: [PATCH 1/4] ovpn sanitization https://github.com/alexbelgium/hassio-addons/issues/1127 --- qbittorrent/rootfs/etc/cont-init.d/00-openvpn.sh | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/qbittorrent/rootfs/etc/cont-init.d/00-openvpn.sh b/qbittorrent/rootfs/etc/cont-init.d/00-openvpn.sh index 0843f7e4d..c5519b77a 100755 --- a/qbittorrent/rootfs/etc/cont-init.d/00-openvpn.sh +++ b/qbittorrent/rootfs/etc/cont-init.d/00-openvpn.sh @@ -31,6 +31,13 @@ if [[ "$(bashio::config "VPN_ENABLED")" == "yes" ]] && [[ "$(bashio::config "VPN # Correct paths sed -i "s=/etc/openvpn=/config/openvpn=g" "$file" + + # Check if the last character in the file is a newline character + last_char=$(tail -c 1 "$file") + if [ "$last_char" != $'\n' ]; then + # Add a blank line at the end of the file + echo >> "$file" + fi fi done From 78bb602b9eb4365b9e118f93d41c88f02a10dde5 Mon Sep 17 00:00:00 2001 From: Alexandre <44178713+alexbelgium@users.noreply.github.com> Date: Thu, 14 Dec 2023 10:07:46 +0100 Subject: [PATCH 2/4] Update CHANGELOG.md --- qbittorrent/CHANGELOG.md | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/qbittorrent/CHANGELOG.md b/qbittorrent/CHANGELOG.md index a8a582088..2f8d09e68 100644 --- a/qbittorrent/CHANGELOG.md +++ b/qbittorrent/CHANGELOG.md @@ -1,5 +1,4 @@ -### 4.6.2-19_wireguard_openvpn (14-12-2023) -- Minor bugs fixed +- Sanitize the ovpn file - Implement a sleep period to wait until vpn is up on faster systems - qbit_manage : add run command From 99572ab5dba3f8447e44df06a76636d90cc57d99 Mon Sep 17 00:00:00 2001 From: Alexandre <44178713+alexbelgium@users.noreply.github.com> Date: Thu, 14 Dec 2023 10:07:59 +0100 Subject: [PATCH 3/4] Update config.json --- qbittorrent/config.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qbittorrent/config.json b/qbittorrent/config.json index 9d598f627..b851751e3 100644 --- a/qbittorrent/config.json +++ b/qbittorrent/config.json @@ -153,5 +153,5 @@ "slug": "qbittorrent", "udev": true, "url": "https://github.com/alexbelgium/hassio-addons", - "version": "4.6.2-19_wireguard_openvpn" + "version": "4.6.2-20_wireguard_openvpn" } From 2d5a156e8a041b2adc811180d354a45b0414d1b4 Mon Sep 17 00:00:00 2001 From: github-actions <41898282+github-actions[bot]@users.noreply.github.com> Date: Thu, 14 Dec 2023 09:14:28 +0000 Subject: [PATCH 4/4] GitHub bot : changelog --- qbittorrent/CHANGELOG.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/qbittorrent/CHANGELOG.md b/qbittorrent/CHANGELOG.md index 2f8d09e68..c30325886 100644 --- a/qbittorrent/CHANGELOG.md +++ b/qbittorrent/CHANGELOG.md @@ -1,3 +1,5 @@ +### 4.6.2-20_wireguard_openvpn (14-12-2023) +- Minor bugs fixed - Sanitize the ovpn file - Implement a sleep period to wait until vpn is up on faster systems - qbit_manage : add run command