From ae0a6d35d8f3700e3b2f194b34be885b8c8abd0d Mon Sep 17 00:00:00 2001 From: Ernesto Baschny Date: Wed, 12 Jul 2023 16:17:56 +0200 Subject: [PATCH] Fix deprecated syntax in chown Avoid deprecation warning: chown: warning: '.' should be ':': 'application.' Since Debian Bookworm contains coreutils 9.1. --- Dockerfile | 2 +- files/entrypoint-extras.sh | 4 ++-- files/ssh/entrypoint.sh | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Dockerfile b/Dockerfile index ea1da57..9bd0be3 100644 --- a/Dockerfile +++ b/Dockerfile @@ -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"] diff --git a/files/entrypoint-extras.sh b/files/entrypoint-extras.sh index 04f7c62..126450d 100644 --- a/files/entrypoint-extras.sh +++ b/files/entrypoint-extras.sh @@ -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 diff --git a/files/ssh/entrypoint.sh b/files/ssh/entrypoint.sh index 435d2e9..a20b178 100755 --- a/files/ssh/entrypoint.sh +++ b/files/ssh/entrypoint.sh @@ -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 < $APP_USER_HOME/.clitools.ini @@ -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