Update 91-configuration.sh

This commit is contained in:
Alexandre
2021-02-14 14:59:03 +01:00
committed by GitHub
parent c156f360b1
commit 6a3a0b3a25

View File

@@ -13,6 +13,15 @@ LINE=$((LINE + 1))
# Default folder #
##################
if bashio::config.has_value 'download-folder'; then
DOWNLOADS=$(bashio::config 'download-folder')
sed -i '/SavePath/d' qBittorrent.conf
sed -i "$LINE i\Downloads\\\SavePath=$DOWNLOADS" qBittorrent.conf
mkdir -p $DOWNLOADS || true
chown -R abc:abc $DOWNLOADS || bashio::log.info "Error, please check default save folder configuration in addon"
bashio::log.info "Downloads folder created"
fi
mkdir -p /share/qBittorrent || true
chown -R abc:abc /share/qBittorrent