Skip to content

Commit

Permalink
Merge pull request #33 from cron-eu/fix-chown
Browse files Browse the repository at this point in the history
Fix deprecated syntax in chown
  • Loading branch information
baschny authored Jul 12, 2023
2 parents 3fa417d + ae0a6d3 commit 459ba1b
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -215,6 +215,6 @@ COPY files/ssh/ /
RUN rm -f /usr/local/etc/php/conf.d/docker-php-ext-xdebug.ini
COPY files/entrypoint-extras.sh /

RUN chmod +x /*.sh && chown -R application. /home/application
RUN chmod +x /*.sh && chown -R application: /home/application

ENTRYPOINT ["/entrypoint.sh"]
4 changes: 2 additions & 2 deletions files/entrypoint-extras.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@ fi

if [ ! -z "${APPLICATION_UID}" ] || [ ! -z "${APPLICATION_GID}" ]; then
echo "* Fixing permissions in /app"
test -d /app && chown application. -R /app
test -d /app && chown application: -R /app
echo "* Fixing permissions in /home/application"
test -d /home/application && find /home/application/ -mount -not -user application -exec chown application. {} \;
test -d /home/application && find /home/application/ -mount -not -user application -exec chown application: {} \;
fi

if [ ! -z "${PHP_INI_OVERRIDE}" ]; then
Expand Down
4 changes: 2 additions & 2 deletions files/ssh/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ database=${DB_NAME}
EOF
fi

chown ${APP_USER}. $APP_USER_HOME/.my.cnf
chown ${APP_USER}: $APP_USER_HOME/.my.cnf

# Create a .clitools.ini
cat <<EOF > $APP_USER_HOME/.clitools.ini
Expand All @@ -117,7 +117,7 @@ fi

# -------------------------------------------------------------------------
# Make sure the /app directory is writeable by the user
test -d /app && chown ${APP_USER}. /app
test -d /app && chown ${APP_USER}: /app

# -------------------------------------------------------------------------
# Extra PHP initialization
Expand Down

0 comments on commit 459ba1b

Please sign in to comment.