Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/nextcloudpi.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorthecalcaholic <6317548+theCalcaholic@users.noreply.github.com>2022-09-28 20:37:40 +0300
committerthecalcaholic <6317548+theCalcaholic@users.noreply.github.com>2022-09-28 20:37:40 +0300
commitfc79b722f227af156d86c670c7072119fb252fbd (patch)
treeebbcb6f67e9da5a81a14bebffebe03a8a2aa3fe4
parentba7b845c73410ed3717a00acd42b3ea7621a1f01 (diff)
run-parts.sh: Fix wrong permissions on /data/database
Signed-off-by: thecalcaholic <6317548+theCalcaholic@users.noreply.github.com>
-rwxr-xr-xbuild/docker/debian-ncp/run-parts.sh9
1 files changed, 6 insertions, 3 deletions
diff --git a/build/docker/debian-ncp/run-parts.sh b/build/docker/debian-ncp/run-parts.sh
index 2b779771..ee254449 100755
--- a/build/docker/debian-ncp/run-parts.sh
+++ b/build/docker/debian-ncp/run-parts.sh
@@ -30,15 +30,16 @@ cleanup()
else
echo 'WARN: Backup creation failed'
fi
- set +x
fi
exit
}
-grep '/data-ro' /etc/mysql/mariadb.conf.d/90-ncp.cnf > /dev/null 2>&1 \
- && echo "WARNING: Looks like you have been affected by a critical bug in NCP that can cause data loss. We're trying" \
+grep '/data-ro' /etc/mysql/mariadb.conf.d/90-ncp.cnf > /dev/null 2>&1 && {
+ echo "WARNING: Looks like you have been affected by a critical bug in NCP that can cause data loss. We're trying" \
"to fix this now, but if you encounter any issues, please check" \
"https://github.com/nextcloud/nextcloudpi/issues/1577#issuecomment-1260830341"
+ chown -R mysql: /data/database || true
+}
sed -i 's|/data-ro|/data|' "/etc/mysql/mariadb.conf.d/90-ncp.cnf" || true
trap cleanup SIGTERM
@@ -87,3 +88,5 @@ done
# wait for trap from 'docker stop'
echo "Init done"
while true; do sleep 0.5; done
+
+}