mirror of
https://github.com/AlistGo/alist.git
synced 2025-04-20 03:08:46 +08:00

* build: add argument INSTALL_ARIA2 to dockerfile * feat: run aria2 in main entrypoint * feat(ci): environment matrix for docker release * improve(ci): allow overwrite artifacts in docker release * fix(ci): permission of alist binary in docker; entrypoint logic * improve(aria2): move aria2 data to /opt/aria2; fix permission issues References: https://github.com/AlistGo/with_aria2/pull/13 Co-authored-by: GoodbyeNJN <cc@fuckwall.cc> * fix(ci): aio image is not taking effect * fix(build): tar command in aria2 installation process (cherry picked from commit 647285408354807bae64df6a20fefb696ff787de) --------- Co-authored-by: GoodbyeNJN <cc@fuckwall.cc>
19 lines
438 B
Bash
19 lines
438 B
Bash
#!/bin/bash
|
|
|
|
umask ${UMASK}
|
|
|
|
if [ "$1" = "version" ]; then
|
|
./alist version
|
|
else
|
|
if [ "$RUN_ARIA2" = "true" ]; then
|
|
chown -R ${PUID}:${PGID} /opt/aria2/
|
|
exec su-exec ${PUID}:${PGID} nohup aria2c \
|
|
--enable-rpc \
|
|
--rpc-allow-origin-all \
|
|
--conf-path=/opt/aria2/.aria2/aria2.conf \
|
|
>/dev/null 2>&1 &
|
|
fi
|
|
|
|
chown -R ${PUID}:${PGID} /opt/alist/
|
|
exec su-exec ${PUID}:${PGID} ./alist server --no-prefix
|
|
fi |