Implementing Cassandra DB & PHP Extension

This commit is contained in:
Stefan Neuhaus
2019-07-25 08:02:59 +02:00
parent a2e997ab2a
commit 9a852e7bc7
6 changed files with 152 additions and 0 deletions

View File

@ -85,6 +85,26 @@ RUN if [ ${INSTALL_AMQP} = true ]; then \
docker-php-ext-install sockets \
;fi
# Install Cassandra drivers:
ARG INSTALL_CASSANDRA=false
RUN if [ ${INSTALL_CASSANDRA} = true ]; then \
apk --update add cassandra-cpp-driver \
;fi
WORKDIR /usr/src
RUN if [ ${INSTALL_CASSANDRA} = true ]; then \
git clone https://github.com/datastax/php-driver.git \
&& cd php-driver/ext \
&& phpize \
&& mkdir -p /usr/src/php-driver/build \
&& cd /usr/src/php-driver/build \
&& ../ext/configure --with-php-config=/usr/bin/php-config7.1 > /dev/null \
&& make clean >/dev/null \
&& make >/dev/null 2>&1 \
&& make install \
&& docker-php-ext-enable cassandra \
;fi
# Install Phalcon ext
ARG INSTALL_PHALCON=false
ARG PHALCON_VERSION