From 45cf2cb52ac76cd0c9ac04c4ad8b77d8df18d90b Mon Sep 17 00:00:00 2001 From: Deon George Date: Wed, 7 Jul 2021 12:21:21 +1000 Subject: [PATCH] Change ODBC to PDO --- Dockerfile | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index d866334..e07a238 100644 --- a/Dockerfile +++ b/Dockerfile @@ -15,7 +15,18 @@ RUN mkdir /opt/ibm && cd /opt/ibm \ && docker-php-ext-enable ibm_db2 \ && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* -# Install PDO ODBC +# Install PDO IBM RUN mkdir -p /home/db2inst1 && ln -s /opt/ibm/dsdriver /home/db2inst1/sqllib \ - && docker-php-ext-configure pdo_odbc --with-pdo-odbc=ibm-db2 \ - && docker-php-ext-install pdo_odbc + && cd /tmp \ + && curl -L http://pecl.php.net/get/PDO_IBM-1.4.1.tgz | tar xzf - \ + && cd PDO_IBM-1.4.1 \ + && phpize && mkdir -p include/php/ext/pdo && cp *.h include/php/ext/pdo \ + && ln -s lib /home/db2inst1/sqllib/lib64 \ + && ./configure --with-pdo-ibm=/home/db2inst1/sqllib \ + && make install \ + && docker-php-ext-enable pdo_ibm \ + && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* + +### Install PDO ODBC +#RUN docker-php-ext-configure pdo_odbc --with-pdo-odbc=ibm-db2 \ +# && docker-php-ext-install pdo_odbc