From e4d2d79b27727b1fee7b08979c6ac92bcbb94f91 Mon Sep 17 00:00:00 2001 From: binhex Date: Thu, 18 Mar 2021 11:58:29 +0000 Subject: [PATCH] bind network int to vpn adapter as qbittorrent attempts dht to vpn endpoint over eth0 --- run/nobody/qbittorrent.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/run/nobody/qbittorrent.sh b/run/nobody/qbittorrent.sh index 7c8a936..6ac587d 100644 --- a/run/nobody/qbittorrent.sh +++ b/run/nobody/qbittorrent.sh @@ -5,6 +5,10 @@ if [[ "${qbittorrent_running}" == "false" ]]; then echo "[info] Removing session lock file (if it exists)..." rm -f /config/qBittorrent/data/BT_backup/session.lock + # set network interface binding to vpn virtual adapter (wg0/tun0/tap0) for qbittorrent on startup + sed -i -e "s~^Connection\\\\Interface\=.*~Connection\\\\Interface\=${VPN_DEVICE_TYPE}~g" '/config/qBittorrent/config/qBittorrent.conf' + sed -i -e "s~^Connection\\\\InterfaceName\=.*~Connection\\\\InterfaceName\=${VPN_DEVICE_TYPE}~g" '/config/qBittorrent/config/qBittorrent.conf' + echo "[info] Attempting to start qBittorrent..." # run qBittorrent (daemonized, non-blocking) - note qbittorrent requires docker privileged flag