Swoole support php5 (#1571)
* php5 fpm support swoole * php5 workspace support swoole
This commit is contained in:
parent
472df4d194
commit
9250326664
|
@ -135,8 +135,12 @@ ARG INSTALL_SWOOLE=false
|
||||||
|
|
||||||
RUN if [ ${INSTALL_SWOOLE} = true ]; then \
|
RUN if [ ${INSTALL_SWOOLE} = true ]; then \
|
||||||
# Install Php Swoole Extension
|
# Install Php Swoole Extension
|
||||||
pecl install swoole \
|
if [ $(php -r "echo PHP_MAJOR_VERSION;") = "5" ]; then \
|
||||||
&& docker-php-ext-enable swoole \
|
pecl install swoole-2.0.11; \
|
||||||
|
else \
|
||||||
|
pecl install swoole; \
|
||||||
|
fi && \
|
||||||
|
docker-php-ext-enable swoole \
|
||||||
;fi
|
;fi
|
||||||
|
|
||||||
###########################################################################
|
###########################################################################
|
||||||
|
|
|
@ -305,7 +305,11 @@ ARG PHP_VERSION=${PHP_VERSION}
|
||||||
|
|
||||||
RUN if [ ${INSTALL_SWOOLE} = true ]; then \
|
RUN if [ ${INSTALL_SWOOLE} = true ]; then \
|
||||||
# Install Php Swoole Extension
|
# Install Php Swoole Extension
|
||||||
pecl -q install swoole && \
|
if [ $(php -r "echo PHP_MAJOR_VERSION;") = "5" ]; then \
|
||||||
|
pecl -q install swoole-2.0.11; \
|
||||||
|
else \
|
||||||
|
pecl -q install swoole; \
|
||||||
|
fi && \
|
||||||
echo "extension=swoole.so" >> /etc/php/${PHP_VERSION}/mods-available/swoole.ini && \
|
echo "extension=swoole.so" >> /etc/php/${PHP_VERSION}/mods-available/swoole.ini && \
|
||||||
ln -s /etc/php/${PHP_VERSION}/mods-available/swoole.ini /etc/php/${PHP_VERSION}/cli/conf.d/20-swoole.ini \
|
ln -s /etc/php/${PHP_VERSION}/mods-available/swoole.ini /etc/php/${PHP_VERSION}/cli/conf.d/20-swoole.ini \
|
||||||
;fi
|
;fi
|
||||||
|
|
Loading…
Reference in New Issue