diff --git a/Dockerfile b/Dockerfile index 6895d0d..6f88eab 100644 --- a/Dockerfile +++ b/Dockerfile @@ -23,7 +23,7 @@ ENV UPDATE_TRACKERS=true \ CUSTOM_TRACKER_URL= \ LISTEN_PORT=6888 \ RPC_PORT=6800 \ - RPC_SECRET= \ + RPC_SECRET=password \ DISK_CACHE= \ IPV6_MODE= \ SPECIAL_MODE= diff --git a/entrypoint.sh b/entrypoint.sh index 334d718..bc60f0d 100644 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -67,7 +67,7 @@ function config_bgmi { bgmi install bgmi source $data_source bgmi config ADMIN_TOKEN $admin_token - bgmi config SAVE_PATH /media/downloads + bgmi config SAVE_PATH $DOWNLOAD_DIR else bgmi upgrade bash /home/bgmi-docker/BGmi/bgmi/others/crontab.sh @@ -135,6 +135,11 @@ function transmission_install { cp /home/bgmi-docker/dl_tools/transmission/transmission_settings.json /bgmi/conf/transmission/settings.json fi + if [ ! -z "${DOWNLOAD_DIR}" ]; then + sed -i "/\"download-dir\"/c\ \"download-dir\": \"$DOWNLOAD_DIR\"," /bgmi/conf/transmission/settings.json + sed -i "/\"incomplete-dir\"/c\ \"incomplete-dir\": \"$DOWNLOAD_DIR\"," /bgmi/conf/transmission/settings.json + fi + } # aria2设置