Created
April 27, 2017 15:27
-
-
Save meridius/d91781e1eaf1f23b0643314d073d7c53 to your computer and use it in GitHub Desktop.
Docker PHP@Alpine not working couchbase PHP extension
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# If not running interactively, don't do anything | |
[[ $- != *i* ]] && return | |
PS1='\n\[\e[1;35m\]\u\[\e[1;34m\]@\[\e[1;32m\]\h \[\e[1;31m\]\w\[\e[1;32m\]\$\[\e[0m\] ' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM php:7.0-alpine | |
# Alpine Linux 3.4 is used | |
COPY ./.bashrc /root/. | |
ENV BUILD_DEPS \ | |
binutils | |
#ENV PHP_EXTENSION_DEPS \ | |
# libcouchbase-dev \ | |
# php7-dev \ | |
# zlib-dev | |
ENV PHP_CONFIG_SCAN_DIR $PHP_INI_DIR/conf.d | |
# Install packages | |
RUN echo http://dl-cdn.alpinelinux.org/alpine/edge/testing >> /etc/apk/repositories \ | |
&& echo http://dl-cdn.alpinelinux.org/alpine/edge/main >> /etc/apk/repositories \ | |
&& echo http://dl-cdn.alpinelinux.org/alpine/edge/community >> /etc/apk/repositories \ | |
&& apk add --update --no-cache \ | |
bash \ | |
php7-intl \ | |
php7-xdebug \ | |
php7-couchbase \ | |
php7-opcache \ | |
$PHPIZE_DEPS \ | |
$BUILD_DEPS | |
# $PHP_EXTENSION_DEPS \ | |
# php7-couchbase=2.2.3-r1 \ | |
# WORKING Enable and configure php extensions | |
COPY ./php/xdebug.ini $PHP_CONFIG_SCAN_DIR/xdebug.ini | |
RUN docker-php-ext-enable /usr/local/lib/php/extensions/no-debug-non-zts-20151012/opcache.so | |
## NOT WORKING ---------------- | |
#RUN pecl channel-update pecl.php.net \ | |
# && pecl install --alldeps pcs-1.3.3 \ | |
# && pecl install --alldeps couchbase | |
# && pecl install --alldeps couchbase-2.2.3 | |
#RUN cp /etc/php7/conf.d/couchbase.ini $PHP_CONFIG_SCAN_DIR/couchbase.ini | |
# takes too long | |
# and | |
# expr: syntax error | |
# /tmp/pear/temp/pcs/configure: line 2517: test: =: unary operator expected | |
# and | |
# PHP Warning: PHP Startup: Unable to load dynamic library '/usr/local/lib/php/extensions/no-debug-non-zts-20151012/couchbase.so' - Error loading shared library /usr/local/lib/php/extensions/no-debug-non-zts-20151012/couchbase.so: No such file or directory in Unknown on line 0 | |
#RUN docker-php-ext-enable /usr/lib/php7/intl.so | |
# nm: /usr/lib/php7/intl.so: no symbols | |
#RUN cp /etc/php7/conf.d/00_intl.ini $PHP_CONFIG_SCAN_DIR/intl.ini | |
# PHP Warning: PHP Startup: Unable to load dynamic library '/usr/local/lib/php/extensions/no-debug-non-zts-20151012/intl.so' - Error loading shared library /usr/local/lib/php/extensions/no-debug-non-zts-20151012/intl.so: No such file or directory in Unknown on line 0 | |
# not even with echo extension=/usr/lib/php7/intl.so > $PHP_CONFIG_SCAN_DIR/intl.ini | |
#COPY ./php/couchbase.ini $PHP_CONFIG_SCAN_DIR/couchbase.ini | |
# PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php7/couchbase.so' - Error relocating /usr/lib/php7/couchbase.so: php_log_err_with_severity: symbol not found in Unknown on line 0 | |
#RUN docker-php-ext-enable /usr/lib/php7/couchbase.so | |
# nm: /usr/lib/php7/couchbase.so: no symbols | |
# PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php7/couchbase.so' - Error relocating /usr/lib/php7/couchbase.so: php_log_err_with_severity: symbol not found in Unknown on line 0 | |
#RUN docker-php-ext-enable /usr/lib/php7/opcache.so | |
# PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php7/opcache.so' - Error relocating /usr/lib/php7/opcache.so: zend_vm_set_opcode_handler_ex: symbol not found in Unknown on line 0 | |
#RUN docker-php-ext-enable /usr/lib/php7/modules/couchbase.so | |
# error: does not exist | |
## ---------------------------- | |
CMD ["bash"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
zend_extension=/usr/lib/php7/modules/xdebug.so | |
xdebug.remote_enable=On | |
xdebug.remote_autostart=0 | |
xdebug.remote_connect_back=1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment