Merge pull request #3148 from tancou/php-worker-8.x-amqp
Fix php worker 8.x amqp
This commit is contained in:
commit
7542f3e595
|
@ -38,7 +38,12 @@ RUN apk --update add wget \
|
||||||
|
|
||||||
|
|
||||||
RUN pecl channel-update pecl.php.net; \
|
RUN pecl channel-update pecl.php.net; \
|
||||||
docker-php-ext-install mysqli mbstring pdo pdo_mysql tokenizer xml pcntl
|
docker-php-ext-install mysqli mbstring pdo pdo_mysql xml pcntl; \
|
||||||
|
if [ $(php -r "echo PHP_MAJOR_VERSION;") = "8" ] && [ $(php -r "echo PHP_MINOR_VERSION;") = "1" ]; then \
|
||||||
|
php -m | grep -q 'tokenizer'; \
|
||||||
|
else \
|
||||||
|
docker-php-ext-install tokenizer; \
|
||||||
|
fi
|
||||||
|
|
||||||
# Add a non-root user:
|
# Add a non-root user:
|
||||||
ARG PUID=1000
|
ARG PUID=1000
|
||||||
|
@ -257,15 +262,16 @@ RUN if [ ${INSTALL_AUDIOWAVEFORM} = true ]; then \
|
||||||
ARG INSTALL_AMQP=false
|
ARG INSTALL_AMQP=false
|
||||||
|
|
||||||
RUN if [ ${INSTALL_AMQP} = true ]; then \
|
RUN if [ ${INSTALL_AMQP} = true ]; then \
|
||||||
|
docker-php-ext-install sockets; \
|
||||||
apk --update add -q rabbitmq-c rabbitmq-c-dev && \
|
apk --update add -q rabbitmq-c rabbitmq-c-dev && \
|
||||||
if [ $(php -r "echo PHP_MAJOR_VERSION;") = "8" ]; then \
|
if [ $(php -r "echo PHP_MAJOR_VERSION;") = "8" ]; then \
|
||||||
printf "\n" | pecl install amqp-1.11.0beta; \
|
printf "\n" | pecl install amqp-1.11.0; \
|
||||||
else \
|
else \
|
||||||
printf "\n" | pecl install amqp; \
|
printf "\n" | pecl install amqp; \
|
||||||
fi && \
|
fi && \
|
||||||
docker-php-ext-enable amqp && \
|
docker-php-ext-enable amqp && \
|
||||||
apk del -q rabbitmq-c-dev && \
|
apk del -q rabbitmq-c-dev; \
|
||||||
docker-php-ext-install sockets \
|
php -m | grep -oiE '^amqp$' \
|
||||||
;fi
|
;fi
|
||||||
|
|
||||||
# Install Gearman:
|
# Install Gearman:
|
||||||
|
|
Loading…
Reference in New Issue