mirror of
https://github.com/paperless-ngx/paperless-ngx.git
synced 2025-04-02 13:45:10 -05:00

This commit fixes a nasty bug, where the docker-entrypoint.sh silently exits without any error message. The test for a lock file can fail and due to the `set -e` at the beginning of the file the bash script exists without starting the paperless application. It is fixed by moving the check for the existence of the lock file into the if statement, where the `set -e` does not trigger an exit in case the statement fails. Additionally this commit enables the script to trap exit signals and in that case deletes the lock file.