php-fpm sql server section: increase install check
This commit is contained in:
parent
21a5d5bf98
commit
cd849dda21
@ -302,11 +302,11 @@ RUN if [ ${INSTALL_LDAP} = true ]; then \
|
||||
#####################################
|
||||
ARG INSTALL_MSSQL=false
|
||||
ENV INSTALL_MSSQL ${INSTALL_MSSQL}
|
||||
|
||||
RUN if [ ${INSTALL_MSSQL} = true ]; then \
|
||||
apt-get -y install php5-sybase freetds-bin && \
|
||||
cp /usr/lib/php5/20131226/*.so /usr/local/lib/php/extensions/no-debug-non-zts-20131226/ && \
|
||||
docker-php-ext-enable mssql pdo pdo_dblib \
|
||||
RUN set -eux; if [ ${INSTALL_MSSQL} = true ]; then \
|
||||
apt-get -y install php5-sybase freetds-bin \
|
||||
&& cp /usr/lib/php5/20131226/*.so /usr/local/lib/php/extensions/no-debug-non-zts-20131226/ \
|
||||
&& docker-php-ext-enable pdo_dblib mssql \
|
||||
&& php -m | grep -q 'mssql' \
|
||||
;fi
|
||||
|
||||
#####################################
|
||||
|
@ -308,10 +308,9 @@ RUN if [ ${INSTALL_LDAP} = true ]; then \
|
||||
#####################################
|
||||
# SQL SERVER:
|
||||
#####################################
|
||||
|
||||
ARG INSTALL_MSSQL=false
|
||||
ENV INSTALL_MSSQL ${INSTALL_MSSQL}
|
||||
RUN if [ ${INSTALL_MSSQL} = true ]; then \
|
||||
RUN set -eux; if [ ${INSTALL_MSSQL} = true ]; then \
|
||||
#####################################
|
||||
# Ref from https://github.com/Microsoft/msphpsql/wiki/Dockerfile-for-adding-pdo_sqlsrv-and-sqlsrv-to-official-php-image
|
||||
#####################################
|
||||
@ -328,6 +327,8 @@ RUN if [ ${INSTALL_MSSQL} = true ]; then \
|
||||
# Install pdo_sqlsrv and sqlsrv from PECL. Replace pdo_sqlsrv-4.1.8preview with preferred version.
|
||||
&& pecl install pdo_sqlsrv-4.1.8preview sqlsrv-4.1.8preview \
|
||||
&& docker-php-ext-enable pdo_sqlsrv sqlsrv \
|
||||
&& php -m | grep -q 'pdo_sqlsrv' \
|
||||
&& php -m | grep -q 'sqlsrv' \
|
||||
;fi
|
||||
|
||||
#####################################
|
||||
|
@ -308,24 +308,27 @@ RUN if [ ${INSTALL_LDAP} = true ]; then \
|
||||
#####################################
|
||||
# SQL SERVER:
|
||||
#####################################
|
||||
|
||||
ARG INSTALL_MSSQL=false
|
||||
ENV INSTALL_MSSQL ${INSTALL_MSSQL}
|
||||
RUN if [ ${INSTALL_MSSQL} = true ]; then \
|
||||
RUN set -eux; if [ ${INSTALL_MSSQL} = true ]; then \
|
||||
#####################################
|
||||
# Ref from https://github.com/Microsoft/msphpsql/wiki/Dockerfile-for-adding-pdo_sqlsrv-and-sqlsrv-to-official-php-image
|
||||
#####################################
|
||||
# Add Microsoft repo for Microsoft ODBC Driver 13 for Linux
|
||||
apt-get update -yqq && apt-get install -y apt-transport-https \
|
||||
apt-get update -yqq \
|
||||
&& apt-get install -y apt-transport-https \
|
||||
&& curl https://packages.microsoft.com/keys/microsoft.asc | apt-key add - \
|
||||
&& curl https://packages.microsoft.com/config/debian/8/prod.list > /etc/apt/sources.list.d/mssql-release.list \
|
||||
&& apt-get update -yqq \
|
||||
# Install Dependencies
|
||||
&& ACCEPT_EULA=Y apt-get install -y unixodbc unixodbc-dev libgss3 odbcinst msodbcsql locales \
|
||||
&& echo "en_US.UTF-8 UTF-8" > /etc/locale.gen && locale-gen \
|
||||
&& echo "en_US.UTF-8 UTF-8" > /etc/locale.gen \
|
||||
&& locale-gen \
|
||||
# Install pdo_sqlsrv and sqlsrv from PECL. Replace pdo_sqlsrv-4.1.8preview with preferred version.
|
||||
&& pecl install pdo_sqlsrv-4.1.8preview sqlsrv-4.1.8preview \
|
||||
&& docker-php-ext-enable pdo_sqlsrv sqlsrv \
|
||||
&& php -m | grep -q 'pdo_sqlsrv' \
|
||||
&& php -m | grep -q 'sqlsrv' \
|
||||
;fi
|
||||
|
||||
#####################################
|
||||
|
@ -311,26 +311,27 @@ RUN if [ ${INSTALL_LDAP} = true ]; then \
|
||||
#####################################
|
||||
# SQL SERVER:
|
||||
#####################################
|
||||
|
||||
ARG INSTALL_MSSQL=false
|
||||
ENV INSTALL_MSSQL ${INSTALL_MSSQL}
|
||||
RUN if [ ${INSTALL_MSSQL} = true ]; then \
|
||||
RUN set -eux; if [ ${INSTALL_MSSQL} = true ]; then \
|
||||
#####################################
|
||||
# Ref from https://github.com/Microsoft/msphpsql/wiki/Dockerfile-for-adding-pdo_sqlsrv-and-sqlsrv-to-official-php-image
|
||||
#####################################
|
||||
# Add Microsoft repo for Microsoft ODBC Driver 13 for Linux
|
||||
apt-get update -yqq && apt-get install -y apt-transport-https gnupg \
|
||||
apt-get update -yqq \
|
||||
&& apt-get install -y apt-transport-https gnupg \
|
||||
&& curl https://packages.microsoft.com/keys/microsoft.asc | apt-key add - \
|
||||
&& curl https://packages.microsoft.com/config/debian/8/prod.list > /etc/apt/sources.list.d/mssql-release.list \
|
||||
&& apt-get update -yqq \
|
||||
|
||||
# Install Dependencies
|
||||
&& ACCEPT_EULA=Y apt-get install -y unixodbc unixodbc-dev libgss3 odbcinst msodbcsql locales \
|
||||
&& echo "en_US.UTF-8 UTF-8" > /etc/locale.gen && locale-gen \
|
||||
|
||||
&& echo "en_US.UTF-8 UTF-8" > /etc/locale.gen \
|
||||
&& locale-gen \
|
||||
# Install pdo_sqlsrv and sqlsrv from PECL. Replace pdo_sqlsrv-4.1.8preview with preferred version.
|
||||
&& pecl install pdo_sqlsrv-4.1.8preview sqlsrv-4.1.8preview \
|
||||
&& docker-php-ext-enable pdo_sqlsrv sqlsrv \
|
||||
&& php -m | grep -q 'pdo_sqlsrv' \
|
||||
&& php -m | grep -q 'sqlsrv' \
|
||||
;fi
|
||||
|
||||
#####################################
|
||||
|
Loading…
Reference in New Issue
Block a user