move supervisord call into wrapper script

This commit is contained in:
Aidan Stein
2022-07-09 17:10:30 -04:00
parent 0f42f2deb6
commit b4fadcc776
3 changed files with 22 additions and 17 deletions

15
docker/paperless_cmd.sh Executable file
View File

@@ -0,0 +1,15 @@
#!/usr/bin/env bash
rootless_args=()
if [ $(id -u) == $(id -u paperless) ]; then
rootless_args=(
--user
paperless
--logfile
supervisord.log
--pidfile
supervisord.pid
)
fi
/usr/local/bin/supervisord -c /etc/supervisord.conf ${rootless_args[@]}