fix xhprof
This commit is contained in:
parent
ffedb02227
commit
c59197c8fd
@ -339,31 +339,38 @@ RUN if [ ${INSTALL_MONGO} = true ]; then \
|
|||||||
|
|
||||||
ARG INSTALL_XHPROF=false
|
ARG INSTALL_XHPROF=false
|
||||||
|
|
||||||
RUN if [ ${INSTALL_XHPROF} = true ]; then \
|
RUN set -eux; \
|
||||||
|
if [ ${INSTALL_XHPROF} = true ]; then \
|
||||||
# Install the php xhprof extension
|
# Install the php xhprof extension
|
||||||
if [ $(php -r "echo PHP_MAJOR_VERSION;") = 7 ]; then \
|
if [ $(php -r "echo PHP_MAJOR_VERSION;") != 5 ]; then \
|
||||||
curl -L -o /tmp/xhprof.tar.gz "https://github.com/tideways/php-xhprof-extension/archive/v5.0.1.tar.gz"; \
|
pecl install xhprof; \
|
||||||
else \
|
else \
|
||||||
curl -L -o /tmp/xhprof.tar.gz "https://codeload.github.com/phacility/xhprof/tar.gz/master"; \
|
curl -L -o /tmp/xhprof.tar.gz "https://codeload.github.com/phacility/xhprof/tar.gz/master"; \
|
||||||
fi \
|
mkdir -p /tmp/xhprof; \
|
||||||
&& mkdir -p xhprof \
|
tar -C /tmp/xhprof -zxvf /tmp/xhprof.tar.gz --strip 1; \
|
||||||
&& tar -C xhprof -zxvf /tmp/xhprof.tar.gz --strip 1 \
|
( \
|
||||||
&& ( \
|
cd /tmp/xhprof/extension; \
|
||||||
cd xhprof \
|
phpize; \
|
||||||
&& phpize \
|
./configure; \
|
||||||
&& ./configure \
|
make; \
|
||||||
&& make \
|
make install; \
|
||||||
&& make install \
|
); \
|
||||||
) \
|
rm -r /tmp/xhprof; \
|
||||||
&& rm -r xhprof \
|
rm /tmp/xhprof.tar.gz; \
|
||||||
&& rm /tmp/xhprof.tar.gz \
|
fi; \
|
||||||
;fi
|
docker-php-ext-enable xhprof; \
|
||||||
|
php -m | grep -q 'xhprof'; \
|
||||||
|
fi
|
||||||
|
|
||||||
COPY ./xhprof.ini /usr/local/etc/php/conf.d
|
# if [ ${INSTALL_XHPROF_USE_TIDYWAYS} = true ]; then \
|
||||||
|
# https://github.com/tideways/php-xhprof-extension
|
||||||
|
# fi
|
||||||
|
|
||||||
RUN if [ ${INSTALL_XHPROF} = false ]; then \
|
# COPY ./xhprof.ini /usr/local/etc/php/conf.d
|
||||||
rm /usr/local/etc/php/conf.d/xhprof.ini \
|
|
||||||
;fi
|
# RUN if [ ${INSTALL_XHPROF} = false ]; then \
|
||||||
|
# rm /usr/local/etc/php/conf.d/xhprof.ini \
|
||||||
|
# ;fi
|
||||||
|
|
||||||
###########################################################################
|
###########################################################################
|
||||||
# AMQP:
|
# AMQP:
|
||||||
|
Loading…
Reference in New Issue
Block a user