Skip to content

Commit

Permalink
Merge pull request #77 from devilbox/release-0.58
Browse files Browse the repository at this point in the history
Add PHP modules: sqlsrv and pdo_sqlsrv for MsSQL
  • Loading branch information
cytopia authored Dec 23, 2018
2 parents 4fa6afe + 2f953cd commit 689703a
Show file tree
Hide file tree
Showing 6 changed files with 100 additions and 4 deletions.
18 changes: 18 additions & 0 deletions Dockerfiles/mods/Dockerfile-7.0
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ ENV BUILD_DEPS \
libxslt-dev \
libzip-dev \
snmp \
unixodbc-dev \
zlib1g-dev \
ca-certificates \
git
Expand Down Expand Up @@ -83,6 +84,7 @@ ENV RUN_DEPS \
libxslt1.1 \
libzip4 \
snmp \
unixodbc \
ca-certificates


Expand Down Expand Up @@ -282,6 +284,12 @@ RUN set -x \
&& (rm -rf /usr/local/lib/php/test/pdo_pgsql || true) \
&& (rm -rf /usr/local/lib/php/doc/pdo_pgsql || true) \
\
# ---- Installing PHP Extension: pdo_sqlsrv ----
&& pecl install pdo_sqlsrv \
&& docker-php-ext-enable pdo_sqlsrv \
&& (rm -rf /usr/local/lib/php/test/pdo_sqlsrv || true) \
&& (rm -rf /usr/local/lib/php/doc/pdo_sqlsrv || true) \
\
# ---- Installing PHP Extension: pgsql ----
&& /usr/local/bin/docker-php-ext-install -j$(getconf _NPROCESSORS_ONLN) pgsql \
&& (rm -rf /usr/local/lib/php/test/pgsql || true) \
Expand Down Expand Up @@ -340,6 +348,12 @@ RUN set -x \
&& (rm -rf /usr/local/lib/php/test/sockets || true) \
&& (rm -rf /usr/local/lib/php/doc/sockets || true) \
\
# ---- Installing PHP Extension: sqlsrv ----
&& pecl install sqlsrv \
&& docker-php-ext-enable sqlsrv \
&& (rm -rf /usr/local/lib/php/test/sqlsrv || true) \
&& (rm -rf /usr/local/lib/php/doc/sqlsrv || true) \
\
# ---- Installing PHP Extension: swoole ----
&& pecl install swoole \
&& docker-php-ext-enable swoole \
Expand Down Expand Up @@ -531,6 +545,8 @@ RUN set -x \
&& php-fpm -m | grep -oiE '^pdo_pgsql$' \
&& php -m | grep -oiE '^pdo_sqlite$' \
&& php-fpm -m | grep -oiE '^pdo_sqlite$' \
&& php -m | grep -oiE '^pdo_sqlsrv$' \
&& php-fpm -m | grep -oiE '^pdo_sqlsrv$' \
&& php -m | grep -oiE '^pgsql$' \
&& php-fpm -m | grep -oiE '^pgsql$' \
&& php -m | grep -oiE '^phalcon$' \
Expand Down Expand Up @@ -561,6 +577,8 @@ RUN set -x \
&& php-fpm -m | grep -oiE '^soap$' \
&& php -m | grep -oiE '^sockets$' \
&& php-fpm -m | grep -oiE '^sockets$' \
&& php -m | grep -oiE '^sqlsrv$' \
&& php-fpm -m | grep -oiE '^sqlsrv$' \
&& php -m | grep -oiE '^swoole$' \
&& php-fpm -m | grep -oiE '^swoole$' \
&& php -m | grep -oiE '^sysvmsg$' \
Expand Down
18 changes: 18 additions & 0 deletions Dockerfiles/mods/Dockerfile-7.1
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ ENV BUILD_DEPS \
libxslt-dev \
libzip-dev \
snmp \
unixodbc-dev \
zlib1g-dev \
ca-certificates \
git
Expand Down Expand Up @@ -83,6 +84,7 @@ ENV RUN_DEPS \
libxslt1.1 \
libzip4 \
snmp \
unixodbc \
ca-certificates


Expand Down Expand Up @@ -277,6 +279,12 @@ RUN set -x \
&& (rm -rf /usr/local/lib/php/test/pdo_pgsql || true) \
&& (rm -rf /usr/local/lib/php/doc/pdo_pgsql || true) \
\
# ---- Installing PHP Extension: pdo_sqlsrv ----
&& pecl install pdo_sqlsrv \
&& docker-php-ext-enable pdo_sqlsrv \
&& (rm -rf /usr/local/lib/php/test/pdo_sqlsrv || true) \
&& (rm -rf /usr/local/lib/php/doc/pdo_sqlsrv || true) \
\
# ---- Installing PHP Extension: pgsql ----
&& /usr/local/bin/docker-php-ext-install -j$(getconf _NPROCESSORS_ONLN) pgsql \
&& (rm -rf /usr/local/lib/php/test/pgsql || true) \
Expand Down Expand Up @@ -335,6 +343,12 @@ RUN set -x \
&& (rm -rf /usr/local/lib/php/test/sockets || true) \
&& (rm -rf /usr/local/lib/php/doc/sockets || true) \
\
# ---- Installing PHP Extension: sqlsrv ----
&& pecl install sqlsrv \
&& docker-php-ext-enable sqlsrv \
&& (rm -rf /usr/local/lib/php/test/sqlsrv || true) \
&& (rm -rf /usr/local/lib/php/doc/sqlsrv || true) \
\
# ---- Installing PHP Extension: swoole ----
&& pecl install swoole \
&& docker-php-ext-enable swoole \
Expand Down Expand Up @@ -526,6 +540,8 @@ RUN set -x \
&& php-fpm -m | grep -oiE '^pdo_pgsql$' \
&& php -m | grep -oiE '^pdo_sqlite$' \
&& php-fpm -m | grep -oiE '^pdo_sqlite$' \
&& php -m | grep -oiE '^pdo_sqlsrv$' \
&& php-fpm -m | grep -oiE '^pdo_sqlsrv$' \
&& php -m | grep -oiE '^pgsql$' \
&& php-fpm -m | grep -oiE '^pgsql$' \
&& php -m | grep -oiE '^phalcon$' \
Expand Down Expand Up @@ -558,6 +574,8 @@ RUN set -x \
&& php-fpm -m | grep -oiE '^soap$' \
&& php -m | grep -oiE '^sockets$' \
&& php-fpm -m | grep -oiE '^sockets$' \
&& php -m | grep -oiE '^sqlsrv$' \
&& php-fpm -m | grep -oiE '^sqlsrv$' \
&& php -m | grep -oiE '^swoole$' \
&& php-fpm -m | grep -oiE '^swoole$' \
&& php -m | grep -oiE '^sysvmsg$' \
Expand Down
18 changes: 18 additions & 0 deletions Dockerfiles/mods/Dockerfile-7.2
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ ENV BUILD_DEPS \
libxslt-dev \
libzip-dev \
snmp \
unixodbc-dev \
zlib1g-dev \
ca-certificates \
git
Expand Down Expand Up @@ -83,6 +84,7 @@ ENV RUN_DEPS \
libxslt1.1 \
libzip4 \
snmp \
unixodbc \
ca-certificates


Expand Down Expand Up @@ -278,6 +280,12 @@ RUN set -x \
&& (rm -rf /usr/local/lib/php/test/pdo_pgsql || true) \
&& (rm -rf /usr/local/lib/php/doc/pdo_pgsql || true) \
\
# ---- Installing PHP Extension: pdo_sqlsrv ----
&& pecl install pdo_sqlsrv \
&& docker-php-ext-enable pdo_sqlsrv \
&& (rm -rf /usr/local/lib/php/test/pdo_sqlsrv || true) \
&& (rm -rf /usr/local/lib/php/doc/pdo_sqlsrv || true) \
\
# ---- Installing PHP Extension: pgsql ----
&& /usr/local/bin/docker-php-ext-install -j$(getconf _NPROCESSORS_ONLN) pgsql \
&& (rm -rf /usr/local/lib/php/test/pgsql || true) \
Expand Down Expand Up @@ -336,6 +344,12 @@ RUN set -x \
&& (rm -rf /usr/local/lib/php/test/sockets || true) \
&& (rm -rf /usr/local/lib/php/doc/sockets || true) \
\
# ---- Installing PHP Extension: sqlsrv ----
&& pecl install sqlsrv \
&& docker-php-ext-enable sqlsrv \
&& (rm -rf /usr/local/lib/php/test/sqlsrv || true) \
&& (rm -rf /usr/local/lib/php/doc/sqlsrv || true) \
\
# ---- Installing PHP Extension: swoole ----
&& pecl install swoole \
&& docker-php-ext-enable swoole \
Expand Down Expand Up @@ -527,6 +541,8 @@ RUN set -x \
&& php-fpm -m | grep -oiE '^pdo_pgsql$' \
&& php -m | grep -oiE '^pdo_sqlite$' \
&& php-fpm -m | grep -oiE '^pdo_sqlite$' \
&& php -m | grep -oiE '^pdo_sqlsrv$' \
&& php-fpm -m | grep -oiE '^pdo_sqlsrv$' \
&& php -m | grep -oiE '^pgsql$' \
&& php-fpm -m | grep -oiE '^pgsql$' \
&& php -m | grep -oiE '^phalcon$' \
Expand Down Expand Up @@ -561,6 +577,8 @@ RUN set -x \
&& php-fpm -m | grep -oiE '^sockets$' \
&& php -m | grep -oiE '^sodium$' \
&& php-fpm -m | grep -oiE '^sodium$' \
&& php -m | grep -oiE '^sqlsrv$' \
&& php-fpm -m | grep -oiE '^sqlsrv$' \
&& php -m | grep -oiE '^swoole$' \
&& php-fpm -m | grep -oiE '^swoole$' \
&& php -m | grep -oiE '^sysvmsg$' \
Expand Down
18 changes: 18 additions & 0 deletions Dockerfiles/mods/Dockerfile-7.3
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ ENV BUILD_DEPS \
libxslt-dev \
libzip-dev \
snmp \
unixodbc-dev \
zlib1g-dev \
ca-certificates \
git
Expand Down Expand Up @@ -82,6 +83,7 @@ ENV RUN_DEPS \
libxslt1.1 \
libzip4 \
snmp \
unixodbc \
ca-certificates


Expand Down Expand Up @@ -237,6 +239,12 @@ RUN set -x \
&& (rm -rf /usr/local/lib/php/test/pdo_pgsql || true) \
&& (rm -rf /usr/local/lib/php/doc/pdo_pgsql || true) \
\
# ---- Installing PHP Extension: pdo_sqlsrv ----
&& pecl install pdo_sqlsrv-5.5.0preview \
&& docker-php-ext-enable pdo_sqlsrv \
&& (rm -rf /usr/local/lib/php/test/pdo_sqlsrv || true) \
&& (rm -rf /usr/local/lib/php/doc/pdo_sqlsrv || true) \
\
# ---- Installing PHP Extension: pgsql ----
&& /usr/local/bin/docker-php-ext-install -j$(getconf _NPROCESSORS_ONLN) pgsql \
&& (rm -rf /usr/local/lib/php/test/pgsql || true) \
Expand Down Expand Up @@ -286,6 +294,12 @@ RUN set -x \
&& (rm -rf /usr/local/lib/php/test/sockets || true) \
&& (rm -rf /usr/local/lib/php/doc/sockets || true) \
\
# ---- Installing PHP Extension: sqlsrv ----
&& pecl install sqlsrv-5.5.0preview \
&& docker-php-ext-enable sqlsrv \
&& (rm -rf /usr/local/lib/php/test/sqlsrv || true) \
&& (rm -rf /usr/local/lib/php/doc/sqlsrv || true) \
\
# ---- Installing PHP Extension: swoole ----
&& git clone https://github.com/swoole/swoole-src /tmp/swoole \
&& cd /tmp/swoole \
Expand Down Expand Up @@ -482,6 +496,8 @@ RUN set -x \
&& php-fpm -m | grep -oiE '^pdo_pgsql$' \
&& php -m | grep -oiE '^pdo_sqlite$' \
&& php-fpm -m | grep -oiE '^pdo_sqlite$' \
&& php -m | grep -oiE '^pdo_sqlsrv$' \
&& php-fpm -m | grep -oiE '^pdo_sqlsrv$' \
&& php -m | grep -oiE '^pgsql$' \
&& php-fpm -m | grep -oiE '^pgsql$' \
&& php -m | grep -oiE '^phar$' \
Expand Down Expand Up @@ -514,6 +530,8 @@ RUN set -x \
&& php-fpm -m | grep -oiE '^sockets$' \
&& php -m | grep -oiE '^sodium$' \
&& php-fpm -m | grep -oiE '^sodium$' \
&& php -m | grep -oiE '^sqlsrv$' \
&& php-fpm -m | grep -oiE '^sqlsrv$' \
&& php -m | grep -oiE '^swoole$' \
&& php-fpm -m | grep -oiE '^swoole$' \
&& php -m | grep -oiE '^sysvmsg$' \
Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -551,22 +551,22 @@ Check out this table to see which Docker image provides what PHP modules.
<tr>
<th>7.0</th>
<td id="70-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, SPL, sqlite3, standard, tokenizer, xml, xmlreader, xmlwriter, zlib</td>
<td id="70-mods">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, rdkafka, 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</td>
<td id="70-mods">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, pdo_sqlsrv, pgsql, phalcon, Phar, posix, pspell, rdkafka, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, 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.1</th>
<td id="71-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, SPL, sqlite3, standard, tokenizer, xml, xmlreader, xmlwriter, zlib</td>
<td id="71-mods">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, rdkafka, 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</td>
<td id="71-mods">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, pdo_sqlsrv, pgsql, phalcon, Phar, posix, pspell, rdkafka, readline, recode, redis, Reflection, session, shmop, SimpleXML, snmp, soap, sockets, 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.2</th>
<td id="72-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="72-mods">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, rdkafka, 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</td>
<td id="72-mods">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, 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.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, 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, memcached, mongodb, mysqli, mysqlnd, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, Phar, posix, pspell, rdkafka, 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</td>
<td id="73-mods">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, memcached, mongodb, mysqli, mysqlnd, openssl, pcntl, pcre, PDO, pdo_dblib, PDO_Firebird, pdo_mysql, 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>
</tr>
<tr>
<th>7.4</th>
Expand Down
24 changes: 24 additions & 0 deletions build/ansible/group_vars/all.yml
Original file line number Diff line number Diff line change
Expand Up @@ -719,6 +719,7 @@ extensions_enabled:
- pdo_odbc
- pdo_pgsql
- pdo_sqlite
- pdo_sqlsrv
- pgsql
- phalcon
- phar
Expand All @@ -737,6 +738,7 @@ extensions_enabled:
- sockets
- sodium
- spl
- sqlsrv
- swoole
- sysvmsg
- sysvsem
Expand Down Expand Up @@ -1203,6 +1205,17 @@ extensions_available:
all:
type: builtin
build_dep: [libsqlite3-dev]
pdo_sqlsrv:
disabled: [5.2, 5.3, 5.4, 5.5, 5.6, 7.4]
7.3:
type: pecl
version: 5.5.0preview
build_dep: [unixodbc-dev]
run_dep: [unixodbc]
all:
type: pecl
build_dep: [unixodbc-dev]
run_dep: [unixodbc]
pgsql:
all:
type: builtin
Expand Down Expand Up @@ -1325,6 +1338,17 @@ extensions_available:
build_dep: [libsodium-dev]
spl:
disabled: "{{ php_all_versions }}" # TODO: Did not work
sqlsrv:
disabled: [5.2, 5.3, 5.4, 5.5, 5.6, 7.4]
7.3:
type: pecl
version: 5.5.0preview
build_dep: [unixodbc-dev]
run_dep: [unixodbc]
all:
type: pecl
build_dep: [unixodbc-dev]
run_dep: [unixodbc]
swoole:
disabled: [5.2]
5.3:
Expand Down

0 comments on commit 689703a

Please sign in to comment.