TheEdgeOfRage
b9793a267b
Some checks failed
continuous-integration/drone/push Build is failing
When running the docker container, the sh script will run as PID 1 and intercept any external signals (like docker stop) and won't pass it on to the app. Docker will wait for 10 seconds before proceeding to force kill the app, leading to both an unclean shutdown and an unnecessary wait of 10 seconds. The exec in the script replaces the shell process with the `su` process, which correctly passes on signals to the app process and triggers a regular shutdown when doing a docker stop. Co-authored-by: Pavle Portic <git@theedgeofrage.com> Reviewed-on: vikunja/api#1200 Reviewed-by: konrad <k@knt.li> Co-authored-by: TheEdgeOfRage <git@theedgeofrage.com> Co-committed-by: TheEdgeOfRage <git@theedgeofrage.com>
7 lines
186 B
Bash
Executable File
7 lines
186 B
Bash
Executable File
#!/bin/sh
|
|
|
|
# Set the uid and gid of the vikunja run user
|
|
usermod --non-unique --uid ${PUID} vikunja
|
|
groupmod --non-unique --gid ${PGID} vikunja
|
|
|
|
exec su vikunja -c '/app/vikunja/vikunja' |