summaryrefslogtreecommitdiffstats
path: root/docker-entrypoint.sh
diff options
context:
space:
mode:
authorJohn Molakvoæ <skjnldsv@protonmail.com>2022-05-31 09:39:13 +0200
committerJohn Molakvoæ <skjnldsv@protonmail.com>2022-06-01 08:18:10 +0200
commit83d5e72596ce76bc7adb02be53a8009ccc2fccee (patch)
tree95db7b17a4f967ebd168e67325809298c72190af /docker-entrypoint.sh
parentd11d42bb208ad39eda3db68b1cfd994bbce4b9c0 (diff)
Add `NEXTCLOUD_INIT_LOCK` to enable shared html volume update
Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
Diffstat (limited to 'docker-entrypoint.sh')
-rwxr-xr-xdocker-entrypoint.sh5
1 files changed, 3 insertions, 2 deletions
diff --git a/docker-entrypoint.sh b/docker-entrypoint.sh
index 6c8f35f4..309524f6 100755
--- a/docker-entrypoint.sh
+++ b/docker-entrypoint.sh
@@ -103,12 +103,13 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
fi
# If another process is syncing the html folder, wait for
- # it to be done, then escape initalization
+ # it to be done, then escape initalization.
+ # You need to define the NEXTCLOUD_INIT_LOCK environment variable
lock=/var/www/html/nextcloud-init-sync.lock
count=0
limit=10
- if [ -f "$lock" ]; then
+ if [ -f "$lock" ] && [ -n "${NEXTCLOUD_INIT_LOCK+x}" ]; then
until [ ! -f "$lock" ] || [ "$count" -gt "$limit" ]
do
count=$((count+1))