Update start.sh

This commit is contained in:
MarkusMcNugen 2018-02-03 05:10:50 -05:00 committed by GitHub
parent 18187c600b
commit 953f142508
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,11 +1,11 @@
#!/bin/bash #!/bin/bash
set -e set -e
function trap_handler #function trap_handler
{ #{
echo "[info] Shutdown detected... copying config file to /config/qbittorrent" | ts '%Y-%m-%d %H:%M:%.S' # echo "[info] Shutdown detected... copying config file to /config/qbittorrent" | ts '%Y-%m-%d %H:%M:%.S'
yes | cp /root/.config/qBittorrent/qBittorrent.conf /config/qbittorrent/qBittorrent.conf # yes | cp /root/.config/qBittorrent/qBittorrent.conf /config/qbittorrent/qBittorrent.conf
} #}
# Make qbittorrent config directory # Make qbittorrent config directory
mkdir -p /config/qbittorrent mkdir -p /config/qbittorrent
@ -27,7 +27,7 @@ else
chmod 644 /root/.config/qBittorrent/qBittorrent.conf chmod 644 /root/.config/qBittorrent/qBittorrent.conf
fi fi
trap trap_handler SIGINT SIGTERM SIGHUP #trap trap_handler SIGINT SIGTERM SIGHUP
echo "[info] Starting qBittorrent daemon..." | ts '%Y-%m-%d %H:%M:%.S' echo "[info] Starting qBittorrent daemon..." | ts '%Y-%m-%d %H:%M:%.S'
/usr/bin/qbittorrent-nox -d /usr/bin/qbittorrent-nox -d