diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index bc13035..4d661f5 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -26,6 +26,7 @@ jobs: - name: Build image ${{ matrix.variant }} ${{ matrix.arch }} run: | + docker pull php:7.3-${{ matrix.variant }} docker build ${{ matrix.variant }} -t monica:${{ matrix.variant }} docker images diff --git a/.templates/Dockerfile-extra.template b/.templates/Dockerfile-extra.template index 8562ac5..2707e14 100644 --- a/.templates/Dockerfile-extra.template +++ b/.templates/Dockerfile-extra.template @@ -12,6 +12,7 @@ ENV PHP_OPCACHE_VALIDATE_TIMESTAMPS="0" \ PHP_OPCACHE_MAX_WASTED_PERCENTAGE="10" RUN set -ex; \ \ + docker-php-ext-enable opcache; \ { \ echo '[opcache]'; \ echo 'opcache.enable=1'; \ @@ -34,3 +35,5 @@ WORKDIR /var/www/html # Define Monica version ENV MONICA_VERSION %%VERSION%% +LABEL org.opencontainers.image.revision="%%COMMIT%%" \ + org.opencontainers.image.version="%%VERSION%%" diff --git a/.templates/Dockerfile-label.template b/.templates/Dockerfile-label.template index a2ba582..626e19c 100644 --- a/.templates/Dockerfile-label.template +++ b/.templates/Dockerfile-label.template @@ -2,7 +2,5 @@ LABEL org.opencontainers.image.authors="Alexis Saettler " \ org.opencontainers.image.title="MonicaHQ, the Personal Relationship Manager" \ org.opencontainers.image.description="This is MonicaHQ, your personal memory! MonicaHQ is like a CRM but for the friends, family, and acquaintances around you." \ org.opencontainers.image.url="https://monicahq.com" \ - org.opencontainers.image.revision="%%COMMIT%%" \ org.opencontainers.image.source="https://github.com/monicahq/docker" \ - org.opencontainers.image.vendor="Monica" \ - org.opencontainers.image.version="%%VERSION%%" + org.opencontainers.image.vendor="Monica" diff --git a/Dockerfile-alpine.template b/Dockerfile-alpine.template index 47db812..9d60336 100644 --- a/Dockerfile-alpine.template +++ b/Dockerfile-alpine.template @@ -21,7 +21,6 @@ RUN set -ex; \ libjpeg-turbo-dev \ jpeg-dev \ gmp-dev \ - libsodium-dev \ libmemcached-dev \ ; \ \ @@ -36,17 +35,12 @@ RUN set -ex; \ docker-php-ext-install -j "$(nproc)" \ intl \ zip \ - json \ - iconv \ bcmath \ gd \ gmp \ pdo_mysql \ mysqli \ soap \ - sodium \ - mbstring \ - opcache \ ; \ # pecl will claim success even if one install fails, so we need to perform each install separately pecl install APCu-%%APCU_VERSION%%; \ diff --git a/Dockerfile-debian.template b/Dockerfile-debian.template index e80ceba..9a95b7c 100644 --- a/Dockerfile-debian.template +++ b/Dockerfile-debian.template @@ -25,7 +25,6 @@ RUN set -ex; \ libfreetype6-dev \ libjpeg62-turbo-dev \ libgmp-dev \ - libsodium-dev \ libmemcached-dev \ ; \ \ @@ -37,17 +36,12 @@ RUN set -ex; \ docker-php-ext-install -j$(nproc) \ intl \ zip \ - json \ - iconv \ bcmath \ gd \ gmp \ pdo_mysql \ mysqli \ soap \ - sodium \ - mbstring \ - opcache \ ; \ \ # pecl will claim success even if one install fails, so we need to perform each install separately diff --git a/apache/Dockerfile b/apache/Dockerfile index f084dd6..7adc59d 100644 --- a/apache/Dockerfile +++ b/apache/Dockerfile @@ -5,10 +5,8 @@ LABEL org.opencontainers.image.authors="Alexis Saettler " \ org.opencontainers.image.title="MonicaHQ, the Personal Relationship Manager" \ org.opencontainers.image.description="This is MonicaHQ, your personal memory! MonicaHQ is like a CRM but for the friends, family, and acquaintances around you." \ org.opencontainers.image.url="https://monicahq.com" \ - org.opencontainers.image.revision="186f336799df2740df28198bfd2431f206668ff2" \ org.opencontainers.image.source="https://github.com/monicahq/docker" \ - org.opencontainers.image.vendor="Monica" \ - org.opencontainers.image.version="v2.18.0" + org.opencontainers.image.vendor="Monica" # entrypoint.sh dependencies RUN set -ex; \ @@ -35,7 +33,6 @@ RUN set -ex; \ libfreetype6-dev \ libjpeg62-turbo-dev \ libgmp-dev \ - libsodium-dev \ libmemcached-dev \ ; \ \ @@ -47,23 +44,18 @@ RUN set -ex; \ docker-php-ext-install -j$(nproc) \ intl \ zip \ - json \ - iconv \ bcmath \ gd \ gmp \ pdo_mysql \ mysqli \ soap \ - sodium \ - mbstring \ - opcache \ ; \ \ # pecl will claim success even if one install fails, so we need to perform each install separately pecl install APCu-5.1.18; \ pecl install memcached-3.1.5; \ - pecl install redis-5.2.2; \ + pecl install redis-5.3.0; \ \ docker-php-ext-enable \ apcu \ @@ -99,6 +91,7 @@ ENV PHP_OPCACHE_VALIDATE_TIMESTAMPS="0" \ PHP_OPCACHE_MAX_WASTED_PERCENTAGE="10" RUN set -ex; \ \ + docker-php-ext-enable opcache; \ { \ echo '[opcache]'; \ echo 'opcache.enable=1'; \ @@ -136,6 +129,8 @@ WORKDIR /var/www/html # Define Monica version ENV MONICA_VERSION v2.18.0 +LABEL org.opencontainers.image.revision="186f336799df2740df28198bfd2431f206668ff2" \ + org.opencontainers.image.version="%%VERSION%%" RUN set -ex; \ fetchDeps=" \ diff --git a/build.sh b/build.sh index 05c1f8a..07c8f7f 100755 --- a/build.sh +++ b/build.sh @@ -3,6 +3,7 @@ set -ex for variant in apache fpm fpm-alpine; do pushd $variant + docker pull php:7.3-$variant docker build --no-cache -t monica:$variant . popd done diff --git a/fpm-alpine/Dockerfile b/fpm-alpine/Dockerfile index 02560e3..11aceed 100644 --- a/fpm-alpine/Dockerfile +++ b/fpm-alpine/Dockerfile @@ -5,10 +5,8 @@ LABEL org.opencontainers.image.authors="Alexis Saettler " \ org.opencontainers.image.title="MonicaHQ, the Personal Relationship Manager" \ org.opencontainers.image.description="This is MonicaHQ, your personal memory! MonicaHQ is like a CRM but for the friends, family, and acquaintances around you." \ org.opencontainers.image.url="https://monicahq.com" \ - org.opencontainers.image.revision="186f336799df2740df28198bfd2431f206668ff2" \ org.opencontainers.image.source="https://github.com/monicahq/docker" \ - org.opencontainers.image.vendor="Monica" \ - org.opencontainers.image.version="v2.18.0" + org.opencontainers.image.vendor="Monica" # entrypoint.sh dependencies RUN set -ex; \ @@ -31,7 +29,6 @@ RUN set -ex; \ libjpeg-turbo-dev \ jpeg-dev \ gmp-dev \ - libsodium-dev \ libmemcached-dev \ ; \ \ @@ -46,22 +43,17 @@ RUN set -ex; \ docker-php-ext-install -j "$(nproc)" \ intl \ zip \ - json \ - iconv \ bcmath \ gd \ gmp \ pdo_mysql \ mysqli \ soap \ - sodium \ - mbstring \ - opcache \ ; \ # pecl will claim success even if one install fails, so we need to perform each install separately pecl install APCu-5.1.18; \ pecl install memcached-3.1.5; \ - pecl install redis-5.2.2; \ + pecl install redis-5.3.0; \ \ docker-php-ext-enable \ apcu \ @@ -92,6 +84,7 @@ ENV PHP_OPCACHE_VALIDATE_TIMESTAMPS="0" \ PHP_OPCACHE_MAX_WASTED_PERCENTAGE="10" RUN set -ex; \ \ + docker-php-ext-enable opcache; \ { \ echo '[opcache]'; \ echo 'opcache.enable=1'; \ @@ -114,6 +107,8 @@ WORKDIR /var/www/html # Define Monica version ENV MONICA_VERSION v2.18.0 +LABEL org.opencontainers.image.revision="186f336799df2740df28198bfd2431f206668ff2" \ + org.opencontainers.image.version="%%VERSION%%" RUN set -ex; \ apk add --no-cache --virtual .fetch-deps \ diff --git a/fpm/Dockerfile b/fpm/Dockerfile index ee90738..1d82ea4 100644 --- a/fpm/Dockerfile +++ b/fpm/Dockerfile @@ -5,10 +5,8 @@ LABEL org.opencontainers.image.authors="Alexis Saettler " \ org.opencontainers.image.title="MonicaHQ, the Personal Relationship Manager" \ org.opencontainers.image.description="This is MonicaHQ, your personal memory! MonicaHQ is like a CRM but for the friends, family, and acquaintances around you." \ org.opencontainers.image.url="https://monicahq.com" \ - org.opencontainers.image.revision="186f336799df2740df28198bfd2431f206668ff2" \ org.opencontainers.image.source="https://github.com/monicahq/docker" \ - org.opencontainers.image.vendor="Monica" \ - org.opencontainers.image.version="v2.18.0" + org.opencontainers.image.vendor="Monica" # entrypoint.sh dependencies RUN set -ex; \ @@ -35,7 +33,6 @@ RUN set -ex; \ libfreetype6-dev \ libjpeg62-turbo-dev \ libgmp-dev \ - libsodium-dev \ libmemcached-dev \ ; \ \ @@ -47,23 +44,18 @@ RUN set -ex; \ docker-php-ext-install -j$(nproc) \ intl \ zip \ - json \ - iconv \ bcmath \ gd \ gmp \ pdo_mysql \ mysqli \ soap \ - sodium \ - mbstring \ - opcache \ ; \ \ # pecl will claim success even if one install fails, so we need to perform each install separately pecl install APCu-5.1.18; \ pecl install memcached-3.1.5; \ - pecl install redis-5.2.2; \ + pecl install redis-5.3.0; \ \ docker-php-ext-enable \ apcu \ @@ -99,6 +91,7 @@ ENV PHP_OPCACHE_VALIDATE_TIMESTAMPS="0" \ PHP_OPCACHE_MAX_WASTED_PERCENTAGE="10" RUN set -ex; \ \ + docker-php-ext-enable opcache; \ { \ echo '[opcache]'; \ echo 'opcache.enable=1'; \ @@ -121,6 +114,8 @@ WORKDIR /var/www/html # Define Monica version ENV MONICA_VERSION v2.18.0 +LABEL org.opencontainers.image.revision="186f336799df2740df28198bfd2431f206668ff2" \ + org.opencontainers.image.version="%%VERSION%%" RUN set -ex; \ fetchDeps=" \