diff --git a/Dockerfiles/mods/Dockerfile-5.3 b/Dockerfiles/mods/Dockerfile-5.3 index 530f0417..2e15ff1d 100644 --- a/Dockerfiles/mods/Dockerfile-5.3 +++ b/Dockerfiles/mods/Dockerfile-5.3 @@ -18,7 +18,6 @@ LABEL \ ### Envs ### ENV BUILD_DEPS \ - wget \ librabbitmq-dev \ libbz2-dev \ libcurl4-openssl-dev \ @@ -119,11 +118,13 @@ RUN set -x \ \ && EXTENSION_DIR="$( php -i | grep ^extension_dir | awk -F '=>' '{print $2}' | xargs )" \ && if [ ! -d "${EXTENSION_DIR}" ]; then mkdir -p "${EXTENSION_DIR}"; fi \ -&& wget https://downloads.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz \ -&& tar xvfz ioncube_loaders_lin_x86-64.tar.gz \ +&& curl https://downloads.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz -L -o ioncube.tar.gz \ +&& tar xvfz ioncube.tar.gz \ && cd ioncube \ && cp "ioncube_loader_lin_5.3.so" "${EXTENSION_DIR}/ioncube.so" \ -&& echo "zend_extension=${EXTENSION_DIR}/ioncube.so" > /usr/local/etc/php/conf.d/docker-php-ext-ioncube.ini \ +&& cd ../ \ +&& rm -rf ioncube \ +&& rm -rf ioncube.tar.gz \ \ && echo "/usr" | pecl install amqp \ && docker-php-ext-enable amqp \ @@ -258,8 +259,6 @@ RUN set -x \ && if [ -n "${PHP_ERROR}" ]; then echo "${PHP_ERROR}"; false; fi RUN set -x \ - && php -m | grep -oiE '^ionCube Loader$' \ - && php-fpm -m | grep -oiE '^ionCube Loader$' \ && php -m | grep -oiE '^amqp$' \ && php-fpm -m | grep -oiE '^amqp$' \ && php -m | grep -oiE '^apcu$' \ diff --git a/Dockerfiles/mods/Dockerfile-5.4 b/Dockerfiles/mods/Dockerfile-5.4 index efa3f1cc..c94b85d9 100644 --- a/Dockerfiles/mods/Dockerfile-5.4 +++ b/Dockerfiles/mods/Dockerfile-5.4 @@ -18,7 +18,6 @@ LABEL \ ### Envs ### ENV BUILD_DEPS \ - wget \ librabbitmq-dev \ libbz2-dev \ libcurl4-openssl-dev \ @@ -119,11 +118,13 @@ RUN set -x \ \ && EXTENSION_DIR="$( php -i | grep ^extension_dir | awk -F '=>' '{print $2}' | xargs )" \ && if [ ! -d "${EXTENSION_DIR}" ]; then mkdir -p "${EXTENSION_DIR}"; fi \ -&& wget https://downloads.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz \ -&& tar xvfz ioncube_loaders_lin_x86-64.tar.gz \ +&& curl https://downloads.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz -L -o ioncube.tar.gz \ +&& tar xvfz ioncube.tar.gz \ && cd ioncube \ && cp "ioncube_loader_lin_5.4.so" "${EXTENSION_DIR}/ioncube.so" \ -&& echo "zend_extension=${EXTENSION_DIR}/ioncube.so" > /usr/local/etc/php/conf.d/docker-php-ext-ioncube.ini \ +&& cd ../ \ +&& rm -rf ioncube \ +&& rm -rf ioncube.tar.gz \ \ && echo "/usr" | pecl install amqp \ && docker-php-ext-enable amqp \ @@ -258,8 +259,6 @@ RUN set -x \ && if [ -n "${PHP_ERROR}" ]; then echo "${PHP_ERROR}"; false; fi RUN set -x \ - && php -m | grep -oiE '^ionCube Loader$' \ - && php-fpm -m | grep -oiE '^ionCube Loader$' \ && php -m | grep -oiE '^amqp$' \ && php-fpm -m | grep -oiE '^amqp$' \ && php -m | grep -oiE '^apcu$' \ diff --git a/Dockerfiles/mods/Dockerfile-5.5 b/Dockerfiles/mods/Dockerfile-5.5 index 84b7ecbc..975c25be 100644 --- a/Dockerfiles/mods/Dockerfile-5.5 +++ b/Dockerfiles/mods/Dockerfile-5.5 @@ -18,7 +18,6 @@ LABEL \ ### Envs ### ENV BUILD_DEPS \ - wget \ librabbitmq-dev \ libbz2-dev \ libcurl4-openssl-dev \ @@ -121,11 +120,13 @@ RUN set -x \ \ && EXTENSION_DIR="$( php -i | grep ^extension_dir | awk -F '=>' '{print $2}' | xargs )" \ && if [ ! -d "${EXTENSION_DIR}" ]; then mkdir -p "${EXTENSION_DIR}"; fi \ -&& wget https://downloads.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz \ -&& tar xvfz ioncube_loaders_lin_x86-64.tar.gz \ +&& curl https://downloads.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz -L -o ioncube.tar.gz \ +&& tar xvfz ioncube.tar.gz \ && cd ioncube \ && cp "ioncube_loader_lin_5.5.so" "${EXTENSION_DIR}/ioncube.so" \ -&& echo "zend_extension=${EXTENSION_DIR}/ioncube.so" > /usr/local/etc/php/conf.d/docker-php-ext-ioncube.ini \ +&& cd ../ \ +&& rm -rf ioncube \ +&& rm -rf ioncube.tar.gz \ \ && echo "/usr" | pecl install amqp \ && docker-php-ext-enable amqp \ @@ -260,8 +261,6 @@ RUN set -x \ && if [ -n "${PHP_ERROR}" ]; then echo "${PHP_ERROR}"; false; fi RUN set -x \ - && php -m | grep -oiE '^ionCube Loader$' \ - && php-fpm -m | grep -oiE '^ionCube Loader$' \ && php -m | grep -oiE '^amqp$' \ && php-fpm -m | grep -oiE '^amqp$' \ && php -m | grep -oiE '^apcu$' \ diff --git a/Dockerfiles/mods/Dockerfile-5.6 b/Dockerfiles/mods/Dockerfile-5.6 index 1ac99177..cff6697c 100644 --- a/Dockerfiles/mods/Dockerfile-5.6 +++ b/Dockerfiles/mods/Dockerfile-5.6 @@ -18,7 +18,6 @@ LABEL \ ### Envs ### ENV BUILD_DEPS \ - wget \ librabbitmq-dev \ libbz2-dev \ libcurl4-openssl-dev \ @@ -123,11 +122,13 @@ RUN set -x \ \ && EXTENSION_DIR="$( php -i | grep ^extension_dir | awk -F '=>' '{print $2}' | xargs )" \ && if [ ! -d "${EXTENSION_DIR}" ]; then mkdir -p "${EXTENSION_DIR}"; fi \ -&& wget https://downloads.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz \ -&& tar xvfz ioncube_loaders_lin_x86-64.tar.gz \ +&& curl https://downloads.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz -L -o ioncube.tar.gz \ +&& tar xvfz ioncube.tar.gz \ && cd ioncube \ && cp "ioncube_loader_lin_5.6.so" "${EXTENSION_DIR}/ioncube.so" \ -&& echo "zend_extension=${EXTENSION_DIR}/ioncube.so" > /usr/local/etc/php/conf.d/docker-php-ext-ioncube.ini \ +&& cd ../ \ +&& rm -rf ioncube \ +&& rm -rf ioncube.tar.gz \ \ && echo "/usr" | pecl install amqp \ && docker-php-ext-enable amqp \ @@ -262,8 +263,6 @@ RUN set -x \ && if [ -n "${PHP_ERROR}" ]; then echo "${PHP_ERROR}"; false; fi RUN set -x \ - && php -m | grep -oiE '^ionCube Loader$' \ - && php-fpm -m | grep -oiE '^ionCube Loader$' \ && php -m | grep -oiE '^amqp$' \ && php-fpm -m | grep -oiE '^amqp$' \ && php -m | grep -oiE '^apcu$' \ diff --git a/Dockerfiles/mods/Dockerfile-7.0 b/Dockerfiles/mods/Dockerfile-7.0 index 40d89eea..0f13eaf1 100644 --- a/Dockerfiles/mods/Dockerfile-7.0 +++ b/Dockerfiles/mods/Dockerfile-7.0 @@ -18,7 +18,6 @@ LABEL \ ### Envs ### ENV BUILD_DEPS \ - wget \ librabbitmq-dev \ libbz2-dev \ libcurl4-openssl-dev \ @@ -121,11 +120,13 @@ RUN set -x \ \ && EXTENSION_DIR="$( php -i | grep ^extension_dir | awk -F '=>' '{print $2}' | xargs )" \ && if [ ! -d "${EXTENSION_DIR}" ]; then mkdir -p "${EXTENSION_DIR}"; fi \ -&& wget https://downloads.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz \ -&& tar xvfz ioncube_loaders_lin_x86-64.tar.gz \ +&& curl https://downloads.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz -L -o ioncube.tar.gz \ +&& tar xvfz ioncube.tar.gz \ && cd ioncube \ && cp "ioncube_loader_lin_7.0.so" "${EXTENSION_DIR}/ioncube.so" \ -&& echo "zend_extension=${EXTENSION_DIR}/ioncube.so" > /usr/local/etc/php/conf.d/docker-php-ext-ioncube.ini \ +&& cd ../ \ +&& rm -rf ioncube \ +&& rm -rf ioncube.tar.gz \ \ && echo "/usr" | pecl install amqp \ && docker-php-ext-enable amqp \ @@ -265,8 +266,6 @@ RUN set -x \ && if [ -n "${PHP_ERROR}" ]; then echo "${PHP_ERROR}"; false; fi RUN set -x \ - && php -m | grep -oiE '^ionCube Loader$' \ - && php-fpm -m | grep -oiE '^ionCube Loader$' \ && php -m | grep -oiE '^amqp$' \ && php-fpm -m | grep -oiE '^amqp$' \ && php -m | grep -oiE '^apcu$' \ diff --git a/Dockerfiles/mods/Dockerfile-7.1 b/Dockerfiles/mods/Dockerfile-7.1 index 58cf9c44..6ef603d4 100644 --- a/Dockerfiles/mods/Dockerfile-7.1 +++ b/Dockerfiles/mods/Dockerfile-7.1 @@ -18,7 +18,6 @@ LABEL \ ### Envs ### ENV BUILD_DEPS \ - wget \ librabbitmq-dev \ libbz2-dev \ libcurl4-openssl-dev \ @@ -121,11 +120,13 @@ RUN set -x \ \ && EXTENSION_DIR="$( php -i | grep ^extension_dir | awk -F '=>' '{print $2}' | xargs )" \ && if [ ! -d "${EXTENSION_DIR}" ]; then mkdir -p "${EXTENSION_DIR}"; fi \ -&& wget https://downloads.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz \ -&& tar xvfz ioncube_loaders_lin_x86-64.tar.gz \ +&& curl https://downloads.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz -L -o ioncube.tar.gz \ +&& tar xvfz ioncube.tar.gz \ && cd ioncube \ && cp "ioncube_loader_lin_7.1.so" "${EXTENSION_DIR}/ioncube.so" \ -&& echo "zend_extension=${EXTENSION_DIR}/ioncube.so" > /usr/local/etc/php/conf.d/docker-php-ext-ioncube.ini \ +&& cd ../ \ +&& rm -rf ioncube \ +&& rm -rf ioncube.tar.gz \ \ && echo "/usr" | pecl install amqp \ && docker-php-ext-enable amqp \ @@ -267,8 +268,6 @@ RUN set -x \ && if [ -n "${PHP_ERROR}" ]; then echo "${PHP_ERROR}"; false; fi RUN set -x \ - && php -m | grep -oiE '^ionCube Loader$' \ - && php-fpm -m | grep -oiE '^ionCube Loader$' \ && php -m | grep -oiE '^amqp$' \ && php-fpm -m | grep -oiE '^amqp$' \ && php -m | grep -oiE '^apcu$' \ diff --git a/Dockerfiles/mods/Dockerfile-7.2 b/Dockerfiles/mods/Dockerfile-7.2 index 76475c15..f28e2fcc 100644 --- a/Dockerfiles/mods/Dockerfile-7.2 +++ b/Dockerfiles/mods/Dockerfile-7.2 @@ -18,7 +18,6 @@ LABEL \ ### Envs ### ENV BUILD_DEPS \ - wget \ librabbitmq-dev \ libbz2-dev \ libcurl4-openssl-dev \ @@ -122,11 +121,13 @@ RUN set -x \ \ && EXTENSION_DIR="$( php -i | grep ^extension_dir | awk -F '=>' '{print $2}' | xargs )" \ && if [ ! -d "${EXTENSION_DIR}" ]; then mkdir -p "${EXTENSION_DIR}"; fi \ -&& wget https://downloads.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz \ -&& tar xvfz ioncube_loaders_lin_x86-64.tar.gz \ +&& curl https://downloads.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz -L -o ioncube.tar.gz \ +&& tar xvfz ioncube.tar.gz \ && cd ioncube \ && cp "ioncube_loader_lin_7.2.so" "${EXTENSION_DIR}/ioncube.so" \ -&& echo "zend_extension=${EXTENSION_DIR}/ioncube.so" > /usr/local/etc/php/conf.d/docker-php-ext-ioncube.ini \ +&& cd ../ \ +&& rm -rf ioncube \ +&& rm -rf ioncube.tar.gz \ \ && pecl install amqp \ && docker-php-ext-enable amqp \ @@ -270,8 +271,6 @@ RUN set -x \ && if [ -n "${PHP_ERROR}" ]; then echo "${PHP_ERROR}"; false; fi RUN set -x \ - && php -m | grep -oiE '^ionCube Loader$' \ - && php-fpm -m | grep -oiE '^ionCube Loader$' \ && php -m | grep -oiE '^amqp$' \ && php-fpm -m | grep -oiE '^amqp$' \ && php -m | grep -oiE '^apcu$' \ diff --git a/Dockerfiles/prod/data/docker-entrypoint.d/38-enable-modules.sh b/Dockerfiles/prod/data/docker-entrypoint.d/38-enable-modules.sh new file mode 100755 index 00000000..68b202e2 --- /dev/null +++ b/Dockerfiles/prod/data/docker-entrypoint.d/38-enable-modules.sh @@ -0,0 +1,51 @@ +#!/usr/bin/env bash + +set -e +set -u +set -o pipefail + + +############################################################ +# Functions +############################################################ + +### +### Enable PHP Modules +### +enable_modules() { + local mod_varname="${1}" + local debug="${2}" + local cfg_path="/usr/local/etc/php/conf.d" + local mod_path= + mod_path="$( php -i | grep ^extension_dir | awk -F '=>' '{print $2}' | xargs )" + + + if ! env_set "${mod_varname}"; then + log "info" "\$${mod_varname} not set. Not enabling any PHP modules." "${debug}" + else + mods="$( env_get "${mod_varname}" )" + + if [ -z "${mods}" ]; then + log "info" "\$${mod_varname} set, but empty. Not enabling any PHP modules." "${debug}" + else + log "info" "Enabling the following PHP modules: ${mods}" "${debug}" + fi + + while read -r mod; do + mod="$( echo "${mod}" | xargs )" # trim + + # Does the module exist? + if [ -f "${mod_path}/${mod}.so" ]; then + # Exceptions to load speficially + if [ "${mod}" = "ioncube" ]; then + run "eche 'zend_extension=${mod_path}/ioncube.so' > '${cfg_path}/docker-ext-php-ext-ioncube.ini'" "${debug}" + # Generic Load + else + run "docker-php-ext-enable ${mod} || true" "${debug}" + fi + else + log "warn" "Enabling PHP Module: '${mod}' does not exist" "${debug}" + fi + done <<< "$( echo "${mods}" | tr ',' '\n' )" + fi +} diff --git a/Dockerfiles/prod/data/docker-entrypoint.d/38-disable-modules.sh b/Dockerfiles/prod/data/docker-entrypoint.d/39-disable-modules.sh similarity index 80% rename from Dockerfiles/prod/data/docker-entrypoint.d/38-disable-modules.sh rename to Dockerfiles/prod/data/docker-entrypoint.d/39-disable-modules.sh index 0c0ee8fa..6ddb99e1 100755 --- a/Dockerfiles/prod/data/docker-entrypoint.d/38-disable-modules.sh +++ b/Dockerfiles/prod/data/docker-entrypoint.d/39-disable-modules.sh @@ -15,7 +15,7 @@ set -o pipefail disable_modules() { local mod_varname="${1}" local debug="${2}" - local mod_path="/usr/local/etc/php/conf.d" + local cfg_path="/usr/local/etc/php/conf.d" if ! env_set "${mod_varname}"; then log "info" "\$${mod_varname} not set. Not disabling any PHP modules." "${debug}" @@ -23,17 +23,16 @@ disable_modules() { mods="$( env_get "${mod_varname}" )" if [ -z "${mods}" ]; then - log "warn" "\$${mod_varname} set, but empty. Not disabling any PHP modules." "${debug}" + log "info" "\$${mod_varname} set, but empty. Not disabling any PHP modules." "${debug}" else log "info" "Disabling the following PHP modules: ${mods}" "${debug}" fi while read -r mod; do - #for mod in ${mods//,/ }; do mod="$( echo "${mod}" | xargs )" # trim # Find all config files that enable that module - files="$( grep -Er "^(zend_)?extension.*(=|/)${mod}\.so" "${mod_path}" || true )" + files="$( grep -Er "^(zend_)?extension.*(=|/)${mod}\.so" "${cfg_path}" || true )" if [ -n "${files}" ]; then while read -r f; do @@ -44,6 +43,5 @@ disable_modules() { done <<< "${files}" fi done <<< "$( echo "${mods}" | tr ',' '\n' )" - #done fi } diff --git a/Dockerfiles/prod/data/docker-entrypoint.sh b/Dockerfiles/prod/data/docker-entrypoint.sh index 3255fa07..3ee6522d 100755 --- a/Dockerfiles/prod/data/docker-entrypoint.sh +++ b/Dockerfiles/prod/data/docker-entrypoint.sh @@ -160,6 +160,12 @@ copy_ini_files "${PHP_CUST_INI_DIR}" "${PHP_INI_DIR}" "${DEBUG_LEVEL}" copy_fpm_files "${PHP_CUST_FPM_DIR}" "${PHP_FPM_DIR}" "${DEBUG_LEVEL}" +### +### Enable PHP Modules +### +enable_modules "ENABLE_MODULES" "${DEBUG_LEVEL}" + + ### ### Disable PHP Modules ### diff --git a/Dockerfiles/work/data/docker-entrypoint.sh b/Dockerfiles/work/data/docker-entrypoint.sh index 038983b0..7e8398a5 100755 --- a/Dockerfiles/work/data/docker-entrypoint.sh +++ b/Dockerfiles/work/data/docker-entrypoint.sh @@ -160,6 +160,12 @@ copy_ini_files "${PHP_CUST_INI_DIR}" "${PHP_INI_DIR}" "${DEBUG_LEVEL}" copy_fpm_files "${PHP_CUST_FPM_DIR}" "${PHP_FPM_DIR}" "${DEBUG_LEVEL}" +### +### Enable PHP Modules +### +enable_modules "ENABLE_MODULES" "${DEBUG_LEVEL}" + + ### ### Disable PHP Modules ### diff --git a/README.md b/README.md index 153f8439..12863ab9 100644 --- a/README.md +++ b/README.md @@ -469,37 +469,37 @@ Check out this table to see which Docker image provides what PHP modules. 5.3 Core, ctype, curl, date, dom, ereg, fileinfo, filter, hash, iconv, json, libxml, mysql, mysqlnd, openssl, pcre, PDO, pdo_sqlite, Phar, posix, readline, recode, Reflection, session, SimpleXML, SPL, SQLite, sqlite3, standard, tokenizer, xml, xmlreader, xmlwriter, zlib - amqp, apc, apcu, bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, ereg, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imagick, imap, interbase, intl, ionCube Loader, json, ldap, libxml, mbstring, mcrypt, memcache, memcached, mongo, mongodb, msgpack, mysql, mysqli, mysqlnd, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, phalcon, Phar, posix, pspell, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, SPL, SQLite, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, the ionCube PHP Loader, tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib + amqp, apc, apcu, bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, ereg, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imagick, imap, interbase, intl, json, ldap, libxml, mbstring, mcrypt, memcache, memcached, mongo, mongodb, msgpack, mysql, mysqli, mysqlnd, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, phalcon, Phar, posix, pspell, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, SPL, SQLite, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib 5.4 Core, ctype, curl, date, dom, ereg, fileinfo, filter, hash, iconv, json, libxml, mysqlnd, openssl, pcre, PDO, pdo_sqlite, Phar, posix, readline, recode, Reflection, session, SimpleXML, SPL, sqlite3, standard, tokenizer, xml, xmlreader, xmlwriter, zlib - amqp, apc, apcu, bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, ereg, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imagick, imap, interbase, intl, ionCube Loader, json, ldap, libxml, mbstring, mcrypt, memcache, memcached, mongo, mongodb, msgpack, mysql, mysqli, mysqlnd, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, phalcon, Phar, posix, pspell, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, SPL, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, the ionCube PHP Loader (enabled) + Intrusion Protection from ioncube24.com (unconfigured), tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib + amqp, apc, apcu, bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, ereg, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imagick, imap, interbase, intl, json, ldap, libxml, mbstring, mcrypt, memcache, memcached, mongo, mongodb, msgpack, mysql, mysqli, mysqlnd, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, phalcon, Phar, posix, pspell, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, SPL, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib 5.5 Core, ctype, curl, date, dom, ereg, fileinfo, filter, ftp, hash, iconv, json, libxml, mbstring, mysqlnd, openssl, pcre, PDO, pdo_sqlite, Phar, posix, readline, Reflection, session, SimpleXML, SPL, sqlite3, standard, tokenizer, xml, xmlreader, xmlwriter, zlib - amqp, apc, apcu, bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, ereg, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imagick, imap, interbase, intl, ionCube Loader, json, ldap, libxml, mbstring, mcrypt, memcache, memcached, mongo, mongodb, msgpack, mysql, mysqli, mysqlnd, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, phalcon, Phar, posix, pspell, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, SPL, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, the ionCube PHP Loader (enabled) + Intrusion Protection from ioncube24.com (unconfigured), tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib + amqp, apc, apcu, bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, ereg, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imagick, imap, interbase, intl, json, ldap, libxml, mbstring, mcrypt, memcache, memcached, mongo, mongodb, msgpack, mysql, mysqli, mysqlnd, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, phalcon, Phar, posix, pspell, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, SPL, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib 5.6 Core, ctype, curl, date, dom, ereg, fileinfo, filter, ftp, hash, iconv, json, libxml, mbstring, mhash, mysqlnd, openssl, pcre, PDO, pdo_sqlite, Phar, posix, readline, Reflection, session, SimpleXML, SPL, sqlite3, standard, tokenizer, xml, xmlreader, xmlwriter, zlib - amqp, apc, apcu, bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, ereg, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imagick, imap, interbase, intl, ionCube Loader, json, ldap, libxml, mbstring, mcrypt, memcache, memcached, mhash, mongo, mongodb, msgpack, mysql, mysqli, mysqlnd, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, phalcon, Phar, posix, pspell, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, SPL, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, the ionCube PHP Loader (enabled) + Intrusion Protection from ioncube24.com (unconfigured), tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib + amqp, apc, apcu, bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, ereg, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imagick, imap, interbase, intl, json, ldap, libxml, mbstring, mcrypt, memcache, memcached, mhash, mongo, mongodb, msgpack, mysql, mysqli, mysqlnd, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, phalcon, Phar, posix, pspell, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, SPL, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib 7.0 Core, ctype, curl, date, dom, fileinfo, filter, ftp, hash, iconv, json, libxml, mbstring, mysqlnd, openssl, pcre, PDO, pdo_sqlite, Phar, posix, readline, Reflection, session, SimpleXML, SPL, sqlite3, standard, tokenizer, xml, xmlreader, xmlwriter, zlib - amqp, apcu, bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imagick, imap, interbase, intl, ionCube Loader, json, ldap, libxml, mbstring, mcrypt, memcache, memcached, mongodb, msgpack, mysqli, mysqlnd, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, phalcon, Phar, posix, pspell, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, SPL, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, the ionCube PHP Loader (enabled) + Intrusion Protection from ioncube24.com (unconfigured), tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib + amqp, apcu, bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imagick, imap, interbase, intl, json, ldap, libxml, mbstring, mcrypt, memcache, memcached, mongodb, msgpack, mysqli, mysqlnd, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, phalcon, Phar, posix, pspell, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, SPL, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib 7.1 Core, ctype, curl, date, dom, fileinfo, filter, ftp, hash, iconv, json, libxml, mbstring, mysqlnd, openssl, pcre, PDO, pdo_sqlite, Phar, posix, readline, Reflection, session, SimpleXML, SPL, sqlite3, standard, tokenizer, xml, xmlreader, xmlwriter, zlib - amqp, apcu, bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imagick, imap, interbase, intl, ionCube Loader, json, ldap, libxml, mbstring, mcrypt, memcache, memcached, mongodb, msgpack, mysqli, mysqlnd, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, phalcon, Phar, posix, pspell, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, SPL, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, the ionCube PHP Loader (enabled) + Intrusion Protection from ioncube24.com (unconfigured), tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib + amqp, apcu, bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imagick, imap, interbase, intl, json, ldap, libxml, mbstring, mcrypt, memcache, memcached, mongodb, msgpack, mysqli, mysqlnd, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, phalcon, Phar, posix, pspell, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, SPL, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib 7.2 Core, ctype, curl, date, dom, fileinfo, filter, ftp, hash, iconv, json, libxml, mbstring, mysqlnd, openssl, pcre, PDO, pdo_sqlite, Phar, posix, readline, Reflection, session, SimpleXML, sodium, SPL, sqlite3, standard, tokenizer, xml, xmlreader, xmlwriter, zlib - amqp, apcu, bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imagick, imap, interbase, intl, ionCube Loader, json, ldap, libxml, mbstring, mcrypt, memcache, memcached, mongodb, msgpack, mysqli, mysqlnd, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, phalcon, Phar, posix, pspell, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, sodium, SPL, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, the ionCube PHP Loader (enabled) + Intrusion Protection from ioncube24.com (unconfigured), tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib + amqp, apcu, bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, enchant, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imagick, imap, interbase, intl, json, ldap, libxml, mbstring, mcrypt, memcache, memcached, mongodb, msgpack, mysqli, mysqlnd, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, phalcon, Phar, posix, pspell, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, sodium, SPL, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib 7.3 @@ -610,7 +610,7 @@ Have a look at the following table to see all supported environment variables fo - prod

work + prod

work TIMEZONE string UTC @@ -622,6 +622,12 @@ Have a look at the following table to see all supported environment variables fo 1 By default all Docker images are configured to output their PHP-FPM access and error logs to stdout and stderr. Those which support it can change the behaviour to log into files inside the container. Their respective directories are available as volumes that can be mounted to the host computer. This feature might help developer who are more comfortable with tailing or searching through actual files instead of using docker logs.

Set this variable to 0 in order to enable logging to files. Log files are avilable under /var/log/php/ which is also a docker volume that can be mounted locally. + + ENABLE_MODULES + string + '' + Comma separated list of PHP modules to enable, which are not enabled by default.
Example:
ENABLE_MODULES=ioncube + DISABLE_MODULES string diff --git a/build/ansible/DOCKERFILES/Dockerfile-mods.j2 b/build/ansible/DOCKERFILES/Dockerfile-mods.j2 index 3fb2b2f8..a1ae34be 100644 --- a/build/ansible/DOCKERFILES/Dockerfile-mods.j2 +++ b/build/ansible/DOCKERFILES/Dockerfile-mods.j2 @@ -188,8 +188,7 @@ RUN set -x \ && php -m | grep -oiE '^Zend Opcache$' \ && php-fpm -m | grep -oiE '^Zend Opcache$' \ {% elif ext == 'ioncube' %} - && php -m | grep -oiE '^ionCube Loader$' \ - && php-fpm -m | grep -oiE '^ionCube Loader$' \ +{# Not enabled #} {% else %} && php -m | grep -oiE '^{{ ext }}$' \ && php-fpm -m | grep -oiE '^{{ ext }}$' \ diff --git a/build/ansible/group_vars/all.yml b/build/ansible/group_vars/all.yml index 353501b8..ab177f1a 100644 --- a/build/ansible/group_vars/all.yml +++ b/build/ansible/group_vars/all.yml @@ -675,13 +675,12 @@ extensions_available: EXTENSION_DIR="$( php -i | grep ^extension_dir | awk -F '=>' '{print $2}' | xargs )" \ && if [ ! -d "${EXTENSION_DIR}" ]; then mkdir -p "${EXTENSION_DIR}"; fi \ && curl https://downloads.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz -L -o ioncube.tar.gz \ - && tar xvfz ioncube_loaders_lin_x86-64.tar.gz \ + && tar xvfz ioncube.tar.gz \ && cd ioncube \ && cp "ioncube_loader_lin_{{ php_version }}.so" "${EXTENSION_DIR}/ioncube.so" \ && cd ../ \ && rm -rf ioncube \ && rm -rf ioncube.tar.gz \ - && echo "zend_extension=${EXTENSION_DIR}/ioncube.so" > /usr/local/etc/php/conf.d/docker-php-ext-ioncube.ini \ json: 7.0: type: builtin