print error when permissions are wrong on common volumes

This commit is contained in:
bunkerity
2021-04-09 14:54:15 +02:00
parent c03d410b0a
commit aa614f82f9
4 changed files with 38 additions and 0 deletions

View File

@@ -2,6 +2,12 @@
echo "[*] Starting autoconf ..."
# check permissions
su -s "/opt/entrypoint/permissions.sh" nginx
if [ "$?" -ne 0 ] ; then
exit 1
fi
if [ "$SWARM_MODE" = "yes" ] ; then
cp -r /opt/confs/nginx/* /etc/nginx
chown -R root:nginx /etc/nginx