Skip to content

Commit

Permalink
Enable more extensions
Browse files Browse the repository at this point in the history
  • Loading branch information
cytopia committed Nov 9, 2019
1 parent 85b743c commit 6b666d0
Show file tree
Hide file tree
Showing 5 changed files with 104 additions and 9 deletions.
2 changes: 1 addition & 1 deletion Dockerfiles/mods/Dockerfile-5.3
Original file line number Diff line number Diff line change
Expand Up @@ -448,7 +448,7 @@ RUN set -eux \
# Custom: Branch
&& git checkout phalcon-v2.0.9 \
# Custom: Install command
&& cd build && ./install >/dev/null \
&& cd build && ./install \
# Enabling
&& docker-php-ext-enable phalcon \
&& true
Expand Down
32 changes: 32 additions & 0 deletions Dockerfiles/mods/Dockerfile-7.3
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ RUN set -eux \
libpng-dev \
libpq-dev \
libpspell-dev \
librabbitmq-dev \
librdkafka-dev \
librecode-dev \
libsasl2-dev \
Expand Down Expand Up @@ -69,6 +70,17 @@ RUN set -eux \
echo "ffi.enable = 1" >> /usr/local/etc/php/conf.d/docker-php-ext-ffi.ini; \
fi

# -------------------- Installing PHP Extension: amqp --------------------
RUN set -eux \
# Installation: Generic
# Type: PECL extension
# Custom: Pecl command
&& echo "/usr" | pecl install amqp \
# Enabling
&& docker-php-ext-enable amqp \
&& true


# -------------------- Installing PHP Extension: apcu --------------------
RUN set -eux \
# Installation: Generic
Expand Down Expand Up @@ -427,6 +439,21 @@ RUN set -eux \
&& true


# -------------------- Installing PHP Extension: phalcon --------------------
RUN set -eux \
# Installation: Generic
# Type: GIT extension
&& git clone https://github.com/phalcon/cphalcon /tmp/phalcon \
&& cd /tmp/phalcon \
# Custom: Branch
&& git checkout $(git for-each-ref --format='%(*creatordate:raw)%(creatordate:raw) %(refname)' refs/tags | sort -n | sed 's/^.*tags\///g' | grep -E '^v[.0-9]+$' | tail -1) \
# Custom: Install command
&& cd build && ./install \
# Enabling
&& docker-php-ext-enable phalcon \
&& true


# -------------------- Installing PHP Extension: pspell --------------------
RUN set -eux \
# Installation: Generic
Expand Down Expand Up @@ -704,6 +731,7 @@ RUN set -eux \
libnghttp2-14 \
libpng16-16 \
libpq5 \
librabbitmq4 \
librdkafka1 \
librecode0 \
libsybdb5 \
Expand Down Expand Up @@ -753,6 +781,8 @@ RUN set -eux \
&& if [ -n "${PHP_FPM_ERROR}" ]; then echo "${PHP_FPM_ERROR}"; false; fi \
&& rm -f /usr/local/etc/php/php.ini \
\
&& php -m | grep -oiE '^amqp$' \
&& php-fpm -m | grep -oiE '^amqp$' \
&& php -m | grep -oiE '^apcu$' \
&& php-fpm -m | grep -oiE '^apcu$' \
&& php -m | grep -oiE '^bcmath$' \
Expand Down Expand Up @@ -849,6 +879,8 @@ RUN set -eux \
&& php-fpm -m | grep -oiE '^pdo_sqlsrv$' \
&& php -m | grep -oiE '^pgsql$' \
&& php-fpm -m | grep -oiE '^pgsql$' \
&& php -m | grep -oiE '^phalcon$' \
&& php-fpm -m | grep -oiE '^phalcon$' \
&& php -m | grep -oiE '^phar$' \
&& php-fpm -m | grep -oiE '^phar$' \
&& php -m | grep -oiE '^posix$' \
Expand Down
58 changes: 58 additions & 0 deletions Dockerfiles/mods/Dockerfile-7.4
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,14 @@ RUN set -eux \
libicu-dev \
libjpeg-dev \
libldap2-dev \
libmagickwand-dev \
libmcrypt-dev \
libmemcached-dev \
libnghttp2-dev \
libpng-dev \
libpq-dev \
libpspell-dev \
librabbitmq-dev \
librdkafka-dev \
libsasl2-dev \
libsnmp-dev \
Expand Down Expand Up @@ -61,6 +64,17 @@ RUN set -eux \
echo "ffi.enable = 1" >> /usr/local/etc/php/conf.d/docker-php-ext-ffi.ini; \
fi

# -------------------- Installing PHP Extension: amqp --------------------
RUN set -eux \
# Installation: Generic
# Type: PECL extension
# Custom: Pecl command
&& echo "/usr" | pecl install amqp \
# Enabling
&& docker-php-ext-enable amqp \
&& true


# -------------------- Installing PHP Extension: bcmath --------------------
RUN set -eux \
# Installation: Generic
Expand Down Expand Up @@ -160,6 +174,17 @@ RUN set -eux \
&& true


# -------------------- Installing PHP Extension: imagick --------------------
RUN set -eux \
# Installation: Version specific
# Type: PECL extension
# Default: Pecl command
&& pecl install imagick \
# Enabling
&& docker-php-ext-enable imagick \
&& true


# -------------------- Installing PHP Extension: intl --------------------
RUN set -eux \
# Installation: Version specific
Expand All @@ -181,6 +206,28 @@ RUN set -eux \
&& true


# -------------------- Installing PHP Extension: mcrypt --------------------
RUN set -eux \
# Installation: Version specific
# Type: PECL extension
# Default: Pecl command
&& pecl install mcrypt \
# Enabling
&& docker-php-ext-enable mcrypt \
&& true


# -------------------- Installing PHP Extension: msgpack --------------------
RUN set -eux \
# Installation: Generic
# Type: PECL extension
# Default: Pecl command
&& pecl install msgpack \
# Enabling
&& docker-php-ext-enable msgpack \
&& true


# -------------------- Installing PHP Extension: memcached --------------------
RUN set -eux \
# Installation: Version specific
Expand Down Expand Up @@ -584,10 +631,13 @@ RUN set -eux \
libhiredis0.13 \
libicu57 \
libjpeg62-turbo \
libmagickwand-6.q16-3 \
libmcrypt4 \
libmemcachedutil2 \
libnghttp2-14 \
libpng16-16 \
libpq5 \
librabbitmq4 \
librdkafka1 \
libsybdb5 \
libtidy5 \
Expand Down Expand Up @@ -635,6 +685,8 @@ RUN set -eux \
&& if [ -n "${PHP_FPM_ERROR}" ]; then echo "${PHP_FPM_ERROR}"; false; fi \
&& rm -f /usr/local/etc/php/php.ini \
\
&& php -m | grep -oiE '^amqp$' \
&& php-fpm -m | grep -oiE '^amqp$' \
&& php -m | grep -oiE '^bcmath$' \
&& php-fpm -m | grep -oiE '^bcmath$' \
&& php -m | grep -oiE '^bz2$' \
Expand Down Expand Up @@ -671,6 +723,8 @@ RUN set -eux \
&& php-fpm -m | grep -oiE '^iconv$' \
&& php -m | grep -oiE '^igbinary$' \
&& php-fpm -m | grep -oiE '^igbinary$' \
&& php -m | grep -oiE '^imagick$' \
&& php-fpm -m | grep -oiE '^imagick$' \
&& php -m | grep -oiE '^intl$' \
&& php-fpm -m | grep -oiE '^intl$' \
&& php -m | grep -oiE '^json$' \
Expand All @@ -681,6 +735,10 @@ RUN set -eux \
&& php-fpm -m | grep -oiE '^libxml$' \
&& php -m | grep -oiE '^mbstring$' \
&& php-fpm -m | grep -oiE '^mbstring$' \
&& php -m | grep -oiE '^mcrypt$' \
&& php-fpm -m | grep -oiE '^mcrypt$' \
&& php -m | grep -oiE '^msgpack$' \
&& php-fpm -m | grep -oiE '^msgpack$' \
&& php -m | grep -oiE '^memcached$' \
&& php-fpm -m | grep -oiE '^memcached$' \
&& php -m | grep -oiE '^mongodb$' \
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -642,12 +642,12 @@ Check out this table to see which Docker image provides what PHP modules.
<tr>
<th>7.3</th>
<td id="73-base">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</td>
<td id="73-mods">apcu, bcmath, blackfire, 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, memcached, mongodb, msgpack, mysqli, mysqlnd, OAuth, oci8, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, PDO_OCI, pdo_pgsql, pdo_sqlite, pdo_sqlsrv, pgsql, Phar, posix, pspell, rdkafka, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, sodium, SPL, sqlite3, sqlsrv, standard, swoole, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib</td>
<td id="73-mods">amqp, apcu, bcmath, blackfire, 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, memcached, mongodb, msgpack, mysqli, mysqlnd, OAuth, oci8, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, PDO_OCI, pdo_pgsql, pdo_sqlite, pdo_sqlsrv, pgsql, phalcon, Phar, posix, pspell, rdkafka, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, sodium, SPL, sqlite3, sqlsrv, standard, swoole, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, uploadprogress, wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib</td>
</tr>
<tr>
<th>7.4</th>
<td id="74-base">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</td>
<td id="74-mods">bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, exif, FFI, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, intl, json, ldap, libxml, mbstring, memcached, mongodb, mysqli, mysqlnd, oci8, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, PDO_OCI, pdo_pgsql, pdo_sqlite, pgsql, Phar, posix, pspell, rdkafka, readline, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, sodium, SPL, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, uploadprogress, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib</td>
<td id="74-mods">amqp, bcmath, bz2, calendar, Core, ctype, curl, date, dba, dom, exif, FFI, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, igbinary, imagick, intl, json, ldap, libxml, mbstring, mcrypt, memcached, mongodb, msgpack, mysqli, mysqlnd, oci8, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, PDO_OCI, pdo_pgsql, pdo_sqlite, pgsql, Phar, posix, pspell, rdkafka, readline, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, sodium, SPL, sqlite3, standard, swoole, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, uploadprogress, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, Zend OPcache, zip, zlib</td>
</tr>
<tr>
<th>8.0</th>
Expand Down
17 changes: 11 additions & 6 deletions build/ansible/group_vars/all/mods.yml
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ extensions_enabled:
# command: [required] Custom command to install and enable a module
extensions_available:
amqp:
disabled: [7.3, 7.4, 8.0]
disabled: [8.0]
5.2:
run_dep: [librabbitmq1]
type: pecl
Expand Down Expand Up @@ -340,7 +340,7 @@ extensions_available:
all:
type: pecl
imagick:
disabled: [5.2, 7.4, 8.0]
disabled: [5.2, 8.0]
5.3:
type: pecl
version: 3.3.0
Expand All @@ -357,6 +357,9 @@ extensions_available:
7.0:
type: pecl
run_dep: [libmagickwand-6.q16-3]
7.4:
type: pecl
run_dep: [libmagickwand-6.q16-3]
all:
type: pecl
build_dep: [libmagickwand-dev]
Expand Down Expand Up @@ -433,13 +436,15 @@ extensions_available:
all:
type: builtin
mcrypt:
disabled: [7.4, 8.0]
disabled: [8.0]
7.2:
type: pecl
version: 1.0.1
7.3:
type: pecl
version: 1.0.2
7.4:
type: pecl
all:
type: builtin
run_dep: [libmcrypt4]
Expand Down Expand Up @@ -558,7 +563,7 @@ extensions_available:
type: pecl
build_dep: [libssl-dev, libsasl2-dev]
msgpack:
disabled: [7.4, 8.0]
disabled: [8.0]
5.2:
type: pecl
version: 0.5.7
Expand Down Expand Up @@ -737,12 +742,12 @@ extensions_available:
build_dep: [libpq-dev]
run_dep: [libpq5]
phalcon:
disabled: [5.2, 7.3, 7.4, 8.0] # TODO: currently disabled for 7.3 as it breaks
disabled: [5.2, 7.4, 8.0] # TODO: currently disabled for 7.4 as it breaks
5.3:
type: git
git_url: https://github.com/phalcon/cphalcon
git_ref: phalcon-v2.0.9
command: cd build && ./install >/dev/null
command: cd build && ./install
5.4:
type: git
git_url: https://github.com/phalcon/cphalcon
Expand Down

0 comments on commit 6b666d0

Please sign in to comment.