From f58c2d0a7bfabe3b73a4c6ab2aa4b8833ea82402 Mon Sep 17 00:00:00 2001 From: Aidan Stein Date: Sun, 3 Jul 2022 14:42:36 -0400 Subject: [PATCH] allow rootless (as paperless user) --- docker/docker-entrypoint.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/docker/docker-entrypoint.sh b/docker/docker-entrypoint.sh index c1e7588e1..b68eeb409 100755 --- a/docker/docker-entrypoint.sh +++ b/docker/docker-entrypoint.sh @@ -95,7 +95,11 @@ initialize() { done set -e - gosu paperless /sbin/docker-prepare.sh + if [ $(id -u) == $(id -u paperless) ]; then + /sbin/docker-prepare.sh + else + gosu paperless /sbin/docker-prepare.sh + fi } install_languages() {