fix(cassandra extension): get installed cassandra for horizon and worker images
Setup the installation on laravel-horizon and php-worker images. Closes #2876
This commit is contained in:
@ -178,21 +178,24 @@ RUN if [ ${INSTALL_AUDIOWAVEFORM} = true ]; then \
|
||||
# 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 > /dev/null \
|
||||
&& make clean >/dev/null \
|
||||
&& make >/dev/null 2>&1 \
|
||||
&& make install \
|
||||
&& docker-php-ext-enable cassandra \
|
||||
if [ $(php -r "echo PHP_MAJOR_VERSION;") = "8" ]; then \
|
||||
echo "PHP Driver for Cassandra is not supported for PHP 8.0."; \
|
||||
else \
|
||||
apk add --update --no-cache cassandra-cpp-driver libuv gmp \
|
||||
&& apk add --update --no-cache cassandra-cpp-driver-dev gmp-dev --virtual .build-sec \
|
||||
&& cd /usr/src \
|
||||
&& 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 > /dev/null \
|
||||
&& make clean > /dev/null \
|
||||
&& make > /dev/null 2>&1 \
|
||||
&& make install \
|
||||
&& docker-php-ext-enable cassandra \
|
||||
&& apk del .build-sec; \
|
||||
fi \
|
||||
;fi
|
||||
|
||||
# Install MongoDB drivers:
|
||||
|
Reference in New Issue
Block a user