diff --git a/docker-compose.yml b/docker-compose.yml index 45ddf33..e28ac75 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -75,7 +75,6 @@ services: - INSTALL_WP_CLI=${WORKSPACE_INSTALL_WP_CLI} - INSTALL_DRUPAL_CONSOLE=${WORKSPACE_INSTALL_DRUPAL_CONSOLE} - INSTALL_AEROSPIKE=${WORKSPACE_INSTALL_AEROSPIKE} - - AEROSPIKE_PHP_REPOSITORY=${AEROSPIKE_PHP_REPOSITORY} - INSTALL_V8JS=${WORKSPACE_INSTALL_V8JS} - COMPOSER_GLOBAL_INSTALL=${WORKSPACE_COMPOSER_GLOBAL_INSTALL} - COMPOSER_REPO_PACKAGIST=${WORKSPACE_COMPOSER_REPO_PACKAGIST} @@ -146,7 +145,6 @@ services: - INSTALL_OPCACHE=${PHP_FPM_INSTALL_OPCACHE} - INSTALL_EXIF=${PHP_FPM_INSTALL_EXIF} - INSTALL_AEROSPIKE=${PHP_FPM_INSTALL_AEROSPIKE} - - AEROSPIKE_PHP_REPOSITORY=${AEROSPIKE_PHP_REPOSITORY} - INSTALL_MYSQLI=${PHP_FPM_INSTALL_MYSQLI} - INSTALL_PGSQL=${PHP_FPM_INSTALL_PGSQL} - INSTALL_PG_CLIENT=${PHP_FPM_INSTALL_PG_CLIENT} diff --git a/env-example b/env-example index d8eacb0..8623623 100644 --- a/env-example +++ b/env-example @@ -372,11 +372,6 @@ AEROSPIKE_FABRIC_PORT=3001 AEROSPIKE_HEARTBEAT_PORT=3002 AEROSPIKE_INFO_PORT=3003 -# for all versions -AEROSPIKE_PHP_REPOSITORY=https://github.com/aerospike/aerospike-client-php/archive/master.tar.gz -# for php 5.6 -# AEROSPIKE_PHP_REPOSITORY=https://github.com/aerospike/aerospike-client-php5/archive/3.4.15.tar.gz - ### RETHINKDB ############################################# RETHINKDB_PORT=8090 diff --git a/php-fpm/Dockerfile b/php-fpm/Dockerfile index 6fd6fea..a6bfb51 100644 --- a/php-fpm/Dockerfile +++ b/php-fpm/Dockerfile @@ -24,7 +24,7 @@ ARG LARADOCK_PHP_VERSION ENV DEBIAN_FRONTEND noninteractive # always run apt update when start and after add new source list, then clean up at end. -RUN apt-get update -yqq && \ +RUN set -xe && apt-get update -yqq && \ apt-get install -y apt-utils && \ pecl channel-update pecl.php.net @@ -338,30 +338,29 @@ RUN if [ ${INSTALL_EXIF} = true ]; then \ USER root ARG INSTALL_AEROSPIKE=false -ARG AEROSPIKE_PHP_REPOSITORY -RUN if [ ${INSTALL_AEROSPIKE} = true ]; then \ +RUN set -xe && if [ ${INSTALL_AEROSPIKE} = true ]; then \ # Fix dependencies for PHPUnit within aerospike extension apt-get -y install sudo wget && \ # Install the php aerospike extension if [ $(php -r "echo PHP_MAJOR_VERSION;") = "5" ]; then \ curl -L -o /tmp/aerospike-client-php.tar.gz https://github.com/aerospike/aerospike-client-php5/archive/master.tar.gz; \ else \ - curl -L -o /tmp/aerospike-client-php.tar.gz ${AEROSPIKE_PHP_REPOSITORY}; \ + curl -L -o /tmp/aerospike-client-php.tar.gz https://github.com/aerospike/aerospike-client-php/archive/master.tar.gz; \ fi \ - && mkdir -p aerospike-client-php \ - && tar -C aerospike-client-php -zxvf /tmp/aerospike-client-php.tar.gz --strip 1 \ + && mkdir -p /tmp/aerospike-client-php \ + && tar -C /tmp/aerospike-client-php -zxvf /tmp/aerospike-client-php.tar.gz --strip 1 \ && \ if [ $(php -r "echo PHP_MAJOR_VERSION;") = "5" ]; then \ ( \ - cd aerospike-client-php/src/aerospike \ + cd /tmp/aerospike-client-php/src/aerospike \ && phpize \ && ./build.sh \ && make install \ ) \ else \ ( \ - cd aerospike-client-php/src \ + cd /tmp/aerospike-client-php/src \ && phpize \ && ./build.sh \ && make install \ diff --git a/travis-build.sh b/travis-build.sh index eeee67b..d6aec97 100755 --- a/travis-build.sh +++ b/travis-build.sh @@ -15,10 +15,6 @@ if [ -n "${PHP_VERSION}" ]; then sed -i -- "s/PHP_VERSION=.*/PHP_VERSION=${PHP_VERSION}/g" .env sed -i -- 's/=false/=true/g' .env sed -i -- 's/PHPDBG=true/PHPDBG=false/g' .env - if [ "${PHP_VERSION}" == "5.6" ]; then - sed -i -- 's/^AEROSPIKE_PHP_REPOSITORY=/##AEROSPIKE_PHP_REPOSITORY=/g' .env - sed -i -- 's/^# AEROSPIKE_PHP_REPOSITORY=/AEROSPIKE_PHP_REPOSITORY=/g' .env - fi cat .env docker-compose build ${BUILD_SERVICE} docker images diff --git a/workspace/Dockerfile b/workspace/Dockerfile index d0ebdc3..67c3677 100644 --- a/workspace/Dockerfile +++ b/workspace/Dockerfile @@ -37,7 +37,7 @@ ARG PGID=1000 ENV PGID ${PGID} # always run apt update when start and after add new source list, then clean up at end. -RUN apt-get update -yqq && \ +RUN set -xe && apt-get update -yqq && \ pecl channel-update pecl.php.net && \ groupadd -g ${PGID} laradock && \ useradd -u ${PUID} -g laradock -m laradock -G docker_env && \ @@ -581,26 +581,29 @@ ENV PATH $PATH:/home/laradock/.yarn/bin USER root ARG INSTALL_AEROSPIKE=false -ARG AEROSPIKE_PHP_REPOSITORY -RUN if [ ${INSTALL_AEROSPIKE} = true ]; then \ +RUN set -xe && if [ ${INSTALL_AEROSPIKE} = true ]; then \ # Fix dependencies for PHPUnit within aerospike extension apt-get -y install sudo wget && \ # Install the php aerospike extension - curl -L -o /tmp/aerospike-client-php.tar.gz ${AEROSPIKE_PHP_REPOSITORY} \ - && mkdir -p aerospike-client-php \ - && tar -C aerospike-client-php -zxvf /tmp/aerospike-client-php.tar.gz --strip 1 \ + if [ $(php -r "echo PHP_MAJOR_VERSION;") = "5" ]; then \ + curl -L -o /tmp/aerospike-client-php.tar.gz https://github.com/aerospike/aerospike-client-php5/archive/master.tar.gz; \ + else \ + curl -L -o /tmp/aerospike-client-php.tar.gz https://github.com/aerospike/aerospike-client-php/archive/master.tar.gz; \ + fi \ + && mkdir -p /tmp/aerospike-client-php \ + && tar -C /tmp/aerospike-client-php -zxvf /tmp/aerospike-client-php.tar.gz --strip 1 \ && \ if [ $(php -r "echo PHP_MAJOR_VERSION;") = "5" ]; then \ ( \ - cd aerospike-client-php/src/aerospike \ + cd /tmp/aerospike-client-php/src/aerospike \ && phpize \ && ./build.sh \ && make install \ ) \ else \ ( \ - cd aerospike-client-php/src \ + cd /tmp/aerospike-client-php/src \ && phpize \ && ./build.sh \ && make install \