Unverified Commit 43ba898d authored by Yu-Lung Shao (Allen)'s avatar Yu-Lung Shao (Allen) Committed by GitHub

Merge branch 'master' into php-fpm-install-imap

parents 61d38747 3b0f2717
......@@ -10,29 +10,21 @@ env:
- PHP_VERSION=56 BUILD_SERVICE=workspace
- PHP_VERSION=70 BUILD_SERVICE=workspace
- PHP_VERSION=71 BUILD_SERVICE=workspace
- PHP_VERSION=72 BUILD_SERVICE=workspace
- PHP_VERSION=56 BUILD_SERVICE=php-fpm
- PHP_VERSION=70 BUILD_SERVICE=php-fpm
- PHP_VERSION=71 BUILD_SERVICE=php-fpm
- PHP_VERSION=72 BUILD_SERVICE=php-fpm
- PHP_VERSION=hhvm BUILD_SERVICE=hhvm
# - PHP_VERSION=56 BUILD_SERVICE=php-worker
- PHP_VERSION=70 BUILD_SERVICE=php-worker
- PHP_VERSION=71 BUILD_SERVICE=php-worker
- PHP_VERSION=72 BUILD_SERVICE=php-worker
- PHP_VERSION=56 BUILD_SERVICE=mssql
- PHP_VERSION=70 BUILD_SERVICE=mssql
- PHP_VERSION=71 BUILD_SERVICE=mssql
- PHP_VERSION=56 BUILD_SERVICE=rethinkdb
- PHP_VERSION=70 BUILD_SERVICE=rethinkdb
- PHP_VERSION=71 BUILD_SERVICE=rethinkdb
- PHP_VERSION=56 BUILD_SERVICE=aerospike
- PHP_VERSION=70 BUILD_SERVICE=aerospike
- PHP_VERSION=71 BUILD_SERVICE=aerospike
- PHP_VERSION=NA BUILD_SERVICE="mssql rethinkdb aerospike"
- PHP_VERSION=NA BUILD_SERVICE="applications blackfire minio percona nginx caddy apache2 mysql mariadb postgres postgres-postgis neo4j mongo redis"
- PHP_VERSION=NA BUILD_SERVICE="adminer phpmyadmin pgadmin"
- PHP_VERSION=NA BUILD_SERVICE="memcached beanstalkd beanstalkd-console rabbitmq elasticsearch certbot mailhog maildev selenium jenkins proxy proxy2 haproxy"
......
......@@ -1729,3 +1729,13 @@ This error sometimes happens because your Laravel application isn't running on t
## I get stuck when building nginx on `fetch http://mirrors.aliyun.com/alpine/v3.5/main/x86_64/APKINDEX.tar.gz`
As stated on [#749](https://github.com/laradock/laradock/issues/749#issuecomment-293296687), removing the line `RUN sed -i 's/dl-cdn.alpinelinux.org/mirrors.aliyun.com/' /etc/apk/repositories` from `nginx/Dockerfile` solves the problem.
## Custom composer repo packagist url and npm registry url
In China, the origin source of composer and npm is very slow. You can add `WORKSPACE_NPM_REGISTRY` and `WORKSPACE_COMPOSER_REPO_PACKAGIST` config in `.env` to use your custom source.
Example:
```bash
WORKSPACE_NPM_REGISTRY=https://registry.npm.taobao.org
WORKSPACE_COMPOSER_REPO_PACKAGIST=https://packagist.phpcomposer.com
```
\ No newline at end of file
......@@ -23,12 +23,14 @@ services:
- INSTALL_PHPREDIS=${WORKSPACE_INSTALL_PHPREDIS}
- INSTALL_MSSQL=${WORKSPACE_INSTALL_MSSQL}
- INSTALL_NODE=${WORKSPACE_INSTALL_NODE}
- NPM_REGISTRY=${WORKSPACE_NPM_REGISTRY}
- INSTALL_YARN=${WORKSPACE_INSTALL_YARN}
- INSTALL_DRUSH=${WORKSPACE_INSTALL_DRUSH}
- INSTALL_DRUPAL_CONSOLE=${WORKSPACE_INSTALL_DRUPAL_CONSOLE}
- INSTALL_AEROSPIKE=${WORKSPACE_INSTALL_AEROSPIKE}
- INSTALL_V8JS=${WORKSPACE_INSTALL_V8JS}
- COMPOSER_GLOBAL_INSTALL=${WORKSPACE_COMPOSER_GLOBAL_INSTALL}
- COMPOSER_REPO_PACKAGIST=${WORKSPACE_COMPOSER_REPO_PACKAGIST}
- INSTALL_WORKSPACE_SSH=${WORKSPACE_INSTALL_WORKSPACE_SSH}
- INSTALL_LARAVEL_ENVOY=${WORKSPACE_INSTALL_LARAVEL_ENVOY}
- INSTALL_LARAVEL_INSTALLER=${WORKSPACE_INSTALL_LARAVEL_INSTALLER}
......
......@@ -8,9 +8,9 @@
APPLICATION=../
### PHP Version ########################################################################################################
# Select a PHP version of the Workspace and PHP-FPM containers (Does not apply to HHVM). Accepted values: 71 - 70 - 56
# Select a PHP version of the Workspace and PHP-FPM containers (Does not apply to HHVM). Accepted values: 72 - 71 - 70 - 56
PHP_VERSION=71
PHP_VERSION=72
### PHP Interpreter ####################################################################################################
# Select the PHP Interpreter. Accepted values: hhvm - php-fpm
......@@ -67,12 +67,14 @@ WORKSPACE_INSTALL_AMQP=false
WORKSPACE_INSTALL_PHPREDIS=false
WORKSPACE_INSTALL_MSSQL=false
WORKSPACE_INSTALL_NODE=false
WORKSPACE_NPM_REGISTRY=
WORKSPACE_INSTALL_YARN=false
WORKSPACE_INSTALL_DRUSH=false
WORKSPACE_INSTALL_DRUPAL_CONSOLE=false
WORKSPACE_INSTALL_AEROSPIKE=false
WORKSPACE_INSTALL_V8JS=false
WORKSPACE_COMPOSER_GLOBAL_INSTALL=false
WORKSPACE_COMPOSER_REPO_PACKAGIST=
WORKSPACE_INSTALL_WORKSPACE_SSH=false
WORKSPACE_INSTALL_LARAVEL_ENVOY=false
WORKSPACE_INSTALL_LARAVEL_INSTALLER=false
......
......@@ -18,6 +18,8 @@ server {
fastcgi_buffers 16 16k;
fastcgi_buffer_size 32k;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
#fixes timeouts
fastcgi_read_timeout 600;
include fastcgi_params;
}
......
......@@ -18,6 +18,8 @@ server {
fastcgi_buffers 16 16k;
fastcgi_buffer_size 32k;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
#fixes timeouts
fastcgi_read_timeout 600;
include fastcgi_params;
}
......
......@@ -18,6 +18,8 @@ server {
fastcgi_buffers 16 16k;
fastcgi_buffer_size 32k;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
#fixes timeouts
fastcgi_read_timeout 600;
include fastcgi_params;
}
......
......@@ -20,6 +20,8 @@ server {
fastcgi_split_path_info ^(.+\.php)(/.*)$;
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
#fixes timeouts
fastcgi_read_timeout 600;
fastcgi_param HTTPS off;
}
......
......@@ -177,7 +177,8 @@ ARG INSTALL_GMP=false
RUN if [ ${INSTALL_GMP} = true ]; then \
# Install the GMP extension
apt-get update -yqq && \
apt-get install -y libgmp-dev && \
apt-get install -y libgmp-dev && \
ln -s /usr/include/x86_64-linux-gnu/gmp.h /usr/include/gmp.h && \
docker-php-ext-install gmp \
;fi
......@@ -324,7 +325,7 @@ ARG INSTALL_IMAGEMAGICK=false
ENV INSTALL_IMAGEMAGICK ${INSTALL_IMAGEMAGICK}
RUN if [ ${INSTALL_IMAGEMAGICK} = true ]; then \
apt-get update -y && \
apt-get install -y libmagickwand-dev imagemagick && \
apt-get install -y libmagickwand-dev imagemagick && \
pecl install imagick && \
docker-php-ext-enable imagick \
;fi
......@@ -342,6 +343,12 @@ RUN if [ ${INSTALL_IMAP} = true ]; then \
docker-php-ext-install imap \
;fi
#####################################
# Check PHP version:
#####################################
RUN php -v | head -n 1 | grep -q "PHP 5.6."
#
#--------------------------------------------------------------------------
# Final Touch
......
......@@ -318,12 +318,10 @@ RUN if [ ${INSTALL_MSSQL} = true ]; then \
&& curl https://packages.microsoft.com/keys/microsoft.asc | apt-key add - \
&& curl https://packages.microsoft.com/config/debian/8/prod.list > /etc/apt/sources.list.d/mssql-release.list \
&& apt-get update -yqq \
# Install Dependencies
&& ACCEPT_EULA=Y apt-get install -y unixodbc unixodbc-dev libgss3 odbcinst msodbcsql locales \
&& echo "en_US.UTF-8 UTF-8" > /etc/locale.gen \
&& locale-gen \
# Install pdo_sqlsrv and sqlsrv from PECL. Replace pdo_sqlsrv-4.1.8preview with preferred version.
&& pecl install pdo_sqlsrv-4.1.8preview sqlsrv-4.1.8preview \
&& docker-php-ext-enable pdo_sqlsrv sqlsrv \
......@@ -366,6 +364,12 @@ RUN if [ ${INSTALL_IMAP} = true ]; then \
docker-php-ext-install imap \
;fi
#####################################
# Check PHP version:
#####################################
RUN php -v | head -n 1 | grep -q "PHP 7.0."
#
#--------------------------------------------------------------------------
# Final Touch
......
......@@ -224,7 +224,6 @@ RUN if [ ${INSTALL_AEROSPIKE} = true ]; then \
# Fix dependencies for PHPUnit within aerospike extension
apt-get update -yqq && \
apt-get -y install sudo wget && \
# Install the php aerospike extension
curl -L -o /tmp/aerospike-client-php.tar.gz "https://github.com/aerospike/aerospike-client-php/archive/master.tar.gz" \
&& mkdir -p aerospike-client-php \
......@@ -326,11 +325,9 @@ RUN if [ ${INSTALL_MSSQL} = true ]; then \
&& curl https://packages.microsoft.com/keys/microsoft.asc | apt-key add - \
&& curl https://packages.microsoft.com/config/debian/8/prod.list > /etc/apt/sources.list.d/mssql-release.list \
&& apt-get update -yqq \
# Install Dependencies
&& ACCEPT_EULA=Y apt-get install -y unixodbc unixodbc-dev libgss3 odbcinst msodbcsql locales \
&& echo "en_US.UTF-8 UTF-8" > /etc/locale.gen && locale-gen \
# Install pdo_sqlsrv and sqlsrv from PECL. Replace pdo_sqlsrv-4.1.8preview with preferred version.
&& pecl install pdo_sqlsrv-4.1.8preview sqlsrv-4.1.8preview \
&& docker-php-ext-enable pdo_sqlsrv sqlsrv \
......@@ -373,6 +370,12 @@ RUN if [ ${INSTALL_IMAP} = true ]; then \
docker-php-ext-install imap \
;fi
#####################################
# Check PHP version:
#####################################
RUN php -v | head -n 1 | grep -q "PHP 7.1."
#
#--------------------------------------------------------------------------
# Final Touch
......
This diff is collapsed.
......@@ -4,10 +4,13 @@ log_errors=On
; Maximum amount of memory a script may consume (128MB)
; http://php.net/memory-limit
memory_limit = 128M
memory_limit = 256M
; Maximum allowed size for uploaded files.
; http://php.net/upload-max-filesize
upload_max_filesize = 20M
; Sets max size of post data allowed.
; http://php.net/post-max-size
post_max_size = 20M
max_execution_time=600
default_socket_timeout=3600
request_terminate_timeout=600
......@@ -380,7 +380,7 @@ expose_php = On
; Maximum execution time of each script, in seconds
; http://php.net/max-execution-time
; Note: This directive is hardcoded to 0 for the CLI SAPI
max_execution_time = 30
max_execution_time = 600
; Maximum amount of time each script may spend parsing request data. It's a good
; idea to limit this time on productions servers in order to eliminate unexpectedly
......@@ -390,7 +390,7 @@ max_execution_time = 30
; Development Value: 60 (60 seconds)
; Production Value: 60 (60 seconds)
; http://php.net/max-input-time
max_input_time = 60
max_input_time = 120
; Maximum input variable nesting level
; http://php.net/max-input-nesting-level
......@@ -401,7 +401,7 @@ max_input_time = 60
; Maximum amount of memory a script may consume (128MB)
; http://php.net/memory-limit
memory_limit = 128M
memory_limit = 256M
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; Error handling and logging ;
......
......@@ -380,7 +380,7 @@ expose_php = On
; Maximum execution time of each script, in seconds
; http://php.net/max-execution-time
; Note: This directive is hardcoded to 0 for the CLI SAPI
max_execution_time = 30
max_execution_time = 600
; Maximum amount of time each script may spend parsing request data. It's a good
; idea to limit this time on productions servers in order to eliminate unexpectedly
......@@ -390,7 +390,7 @@ max_execution_time = 30
; Development Value: 60 (60 seconds)
; Production Value: 60 (60 seconds)
; http://php.net/max-input-time
max_input_time = 60
max_input_time = 120
; Maximum input variable nesting level
; http://php.net/max-input-nesting-level
......@@ -401,7 +401,7 @@ max_input_time = 60
; Maximum amount of memory a script may consume (128MB)
; http://php.net/memory-limit
memory_limit = 128M
memory_limit = 256M
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; Error handling and logging ;
......
This diff is collapsed.
......@@ -56,6 +56,13 @@ ENTRYPOINT ["/usr/bin/supervisord", "-n", "-c", "/etc/supervisord.conf"]
#
# -- Your awesome modifications go here -- #
#
#--------------------------------------------------------------------------
# Check PHP version
#--------------------------------------------------------------------------
#
RUN php -v | head -n 1 | grep -q "PHP 7.0."
#
#--------------------------------------------------------------------------
......
......@@ -56,6 +56,13 @@ ENTRYPOINT ["/usr/bin/supervisord", "-n", "-c", "/etc/supervisord.conf"]
#
# -- Your awesome modifications go here -- #
#
#--------------------------------------------------------------------------
# Check PHP version
#--------------------------------------------------------------------------
#
RUN php -v | head -n 1 | grep -q "PHP 7.1."
#
#--------------------------------------------------------------------------
......
#
#--------------------------------------------------------------------------
# Image Setup
#--------------------------------------------------------------------------
#
FROM php:7.2-alpine
MAINTAINER Mahmoud Zalt <mahmoud@zalt.me>
RUN apk --update add wget \
curl \
git \
build-base \
libmemcached-dev \
libmcrypt-dev \
libxml2-dev \
zlib-dev \
autoconf \
cyrus-sasl-dev \
libgsasl-dev \
supervisor
RUN docker-php-ext-install mysqli mbstring pdo pdo_mysql tokenizer xml
RUN pecl channel-update pecl.php.net && pecl install memcached mcrypt-1.0.1 && docker-php-ext-enable memcached
# Install PostgreSQL drivers:
ARG INSTALL_PGSQL=false
RUN if [ ${INSTALL_PGSQL} = true ]; then \
apk --update add postgresql-dev \
&& docker-php-ext-install pdo_pgsql \
;fi
RUN rm /var/cache/apk/* \
&& mkdir -p /var/www
#
#--------------------------------------------------------------------------
# Optional Supervisord Configuration
#--------------------------------------------------------------------------
#
# Modify the ./supervisor.conf file to match your App's requirements.
# Make sure you rebuild your container with every change.
#
COPY supervisord.conf /etc/supervisord.conf
ENTRYPOINT ["/usr/bin/supervisord", "-n", "-c", "/etc/supervisord.conf"]
#
#--------------------------------------------------------------------------
# Optional Software's Installation
#--------------------------------------------------------------------------
#
# If you need to modify this image, feel free to do it right here.
#
# -- Your awesome modifications go here -- #
#
#--------------------------------------------------------------------------
# Check PHP version
#--------------------------------------------------------------------------
#
RUN php -v | head -n 1 | grep -q "PHP 7.2."
#
#--------------------------------------------------------------------------
# Final Touch
#--------------------------------------------------------------------------
#
WORKDIR /etc/supervisor/conf.d/
......@@ -127,6 +127,13 @@ RUN if [ ${COMPOSER_GLOBAL_INSTALL} = true ]; then \
composer global install \
;fi
ARG COMPOSER_REPO_PACKAGIST
ENV COMPOSER_REPO_PACKAGIST ${COMPOSER_REPO_PACKAGIST}
RUN if [ ${COMPOSER_REPO_PACKAGIST} ]; then \
composer config -g repo.packagist composer ${COMPOSER_REPO_PACKAGIST} \
;fi
# Export composer vendor path
RUN echo "" >> ~/.bashrc && \
echo 'export PATH="~/.composer/vendor/bin:$PATH"' >> ~/.bashrc
......@@ -263,7 +270,7 @@ RUN if [ ${INSTALL_PHPREDIS} = true ]; then \
ARG INSTALL_SWOOLE=false
RUN if [ ${INSTALL_SWOOLE} = true ]; then \
# Install Php Swoole Extension
pecl -q install swoole-2.0.11 && \
pecl -q install -f swoole-1.10.1 && \
echo "extension=swoole.so" >> /etc/php/5.6/mods-available/swoole.ini && \
ln -s /etc/php/5.6/mods-available/swoole.ini /etc/php/5.6/cli/conf.d/20-swoole.ini \
;fi
......@@ -309,14 +316,19 @@ ARG NODE_VERSION=stable
ENV NODE_VERSION ${NODE_VERSION}
ARG INSTALL_NODE=false
ENV INSTALL_NODE ${INSTALL_NODE}
ARG NPM_REGISTRY
ENV NPM_REGISTRY ${NPM_REGISTRY}
ENV NVM_DIR /home/laradock/.nvm
RUN if [ ${INSTALL_NODE} = true ]; then \
# Install nvm (A Node Version Manager)
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.1/install.sh | bash && \
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.8/install.sh | bash && \
. $NVM_DIR/nvm.sh && \
nvm install ${NODE_VERSION} && \
nvm use ${NODE_VERSION} && \
nvm alias ${NODE_VERSION} && \
if [ ${NPM_REGISTRY} ]; then \
npm config set registry ${NPM_REGISTRY} \
;fi && \
npm install -g gulp bower vue-cli \
;fi
......@@ -340,6 +352,10 @@ RUN if [ ${INSTALL_NODE} = true ]; then \
# Add PATH for node
ENV PATH $PATH:$NVM_DIR/versions/node/v${NODE_VERSION}/bin
RUN if [ ${NPM_REGISTRY} ]; then \
. ~/.bashrc && npm config set registry ${NPM_REGISTRY} \
;fi
#####################################
# YARN:
#####################################
......@@ -428,6 +444,13 @@ RUN if [ ${INSTALL_LARAVEL_ENVOY} = true ]; then \
#####################################
USER root
ARG COMPOSER_REPO_PACKAGIST
ENV COMPOSER_REPO_PACKAGIST ${COMPOSER_REPO_PACKAGIST}
RUN if [ ${COMPOSER_REPO_PACKAGIST} ]; then \
composer config -g repo.packagist composer ${COMPOSER_REPO_PACKAGIST} \
;fi
ARG INSTALL_LARAVEL_INSTALLER=true
ENV INSTALL_LARAVEL_INSTALLER ${INSTALL_LARAVEL_INSTALLER}
......@@ -626,6 +649,12 @@ RUN if [ ${INSTALL_DUSK_DEPS} = true ]; then \
&& rm chromedriver_linux64.zip \
;fi
#####################################
# Check PHP version:
#####################################
RUN php -v | head -n 1 | grep -q "PHP 5.6."
#
#--------------------------------------------------------------------------
# Final Touch
......
......@@ -124,6 +124,13 @@ RUN if [ ${COMPOSER_GLOBAL_INSTALL} = true ]; then \
composer global install \
;fi
ARG COMPOSER_REPO_PACKAGIST
ENV COMPOSER_REPO_PACKAGIST ${COMPOSER_REPO_PACKAGIST}
RUN if [ ${COMPOSER_REPO_PACKAGIST} ]; then \
composer config -g repo.packagist composer ${COMPOSER_REPO_PACKAGIST} \
;fi
# Export composer vendor path
RUN echo "" >> ~/.bashrc && \
echo 'export PATH="~/.composer/vendor/bin:$PATH"' >> ~/.bashrc
......@@ -305,14 +312,19 @@ ARG NODE_VERSION=stable
ENV NODE_VERSION ${NODE_VERSION}
ARG INSTALL_NODE=false
ENV INSTALL_NODE ${INSTALL_NODE}
ARG NPM_REGISTRY
ENV NPM_REGISTRY ${NPM_REGISTRY}
ENV NVM_DIR /home/laradock/.nvm
RUN if [ ${INSTALL_NODE} = true ]; then \
# Install nvm (A Node Version Manager)
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.1/install.sh | bash && \
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.8/install.sh | bash && \
. $NVM_DIR/nvm.sh && \
nvm install ${NODE_VERSION} && \
nvm use ${NODE_VERSION} && \
nvm alias ${NODE_VERSION} && \
if [ ${NPM_REGISTRY} ]; then \
npm config set registry ${NPM_REGISTRY} \
;fi && \
npm install -g gulp bower vue-cli \
;fi
......@@ -336,6 +348,10 @@ RUN if [ ${INSTALL_NODE} = true ]; then \
# Add PATH for node
ENV PATH $PATH:$NVM_DIR/versions/node/v${NODE_VERSION}/bin
RUN if [ ${NPM_REGISTRY} ]; then \
. ~/.bashrc && npm config set registry ${NPM_REGISTRY} \
;fi
#####################################
# YARN:
#####################################
......@@ -441,6 +457,13 @@ RUN if [ ${INSTALL_LARAVEL_ENVOY} = true ]; then \
#####################################
USER root
ARG COMPOSER_REPO_PACKAGIST
ENV COMPOSER_REPO_PACKAGIST ${COMPOSER_REPO_PACKAGIST}
RUN if [ ${COMPOSER_REPO_PACKAGIST} ]; then \
composer config -g repo.packagist composer ${COMPOSER_REPO_PACKAGIST} \
;fi
ARG INSTALL_LARAVEL_INSTALLER=true
ENV INSTALL_LARAVEL_INSTALLER ${INSTALL_LARAVEL_INSTALLER}
......@@ -703,6 +726,12 @@ RUN if [ ${INSTALL_DUSK_DEPS} = true ]; then \
&& rm chromedriver_linux64.zip \
;fi
#####################################
# Check PHP version:
#####################################
RUN php -v | head -n 1 | grep -q "PHP 7.0."
#
#--------------------------------------------------------------------------
# Final Touch
......
......@@ -123,6 +123,13 @@ RUN if [ ${COMPOSER_GLOBAL_INSTALL} = true ]; then \
composer global install \
;fi
ARG COMPOSER_REPO_PACKAGIST
ENV COMPOSER_REPO_PACKAGIST ${COMPOSER_REPO_PACKAGIST}
RUN if [ ${COMPOSER_REPO_PACKAGIST} ]; then \
composer config -g repo.packagist composer ${COMPOSER_REPO_PACKAGIST} \
;fi
#####################################
# Crontab
#####################################
......@@ -301,14 +308,19 @@ ARG NODE_VERSION=stable
ENV NODE_VERSION ${NODE_VERSION}
ARG INSTALL_NODE=false
ENV INSTALL_NODE ${INSTALL_NODE}
ARG NPM_REGISTRY
ENV NPM_REGISTRY ${NPM_REGISTRY}
ENV NVM_DIR /home/laradock/.nvm
RUN if [ ${INSTALL_NODE} = true ]; then \
# Install nvm (A Node Version Manager)
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.1/install.sh | bash && \
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.8/install.sh | bash && \
. $NVM_DIR/nvm.sh && \
nvm install ${NODE_VERSION} && \
nvm use ${NODE_VERSION} && \
nvm alias ${NODE_VERSION} && \
if [ ${NPM_REGISTRY} ]; then \
npm config set registry ${NPM_REGISTRY} \
;fi && \
npm install -g gulp bower vue-cli \
;fi
......@@ -332,6 +344,9 @@ RUN if [ ${INSTALL_NODE} = true ]; then \
# Add PATH for node
ENV PATH $PATH:$NVM_DIR/versions/node/v${NODE_VERSION}/bin
RUN if [ ${NPM_REGISTRY} ]; then \
. ~/.bashrc && npm config set registry ${NPM_REGISTRY} \
;fi
#####################################
# YARN:
......@@ -409,7 +424,7 @@ RUN if [ ${INSTALL_V8JS} = true ]; then \
# Install the php V8JS extension
add-apt-repository -y ppa:pinepain/libv8-5.4 \
&& apt-get update -yqq \
&& apt-get install -y php-xml php-dev php-pear libv8-5.4 \
&& apt-get install -y php7.1-xml php7.1-dev php-pear libv8-5.4 \
&& pecl install v8js \
&& echo "extension=v8js.so" >> /etc/php/7.1/cli/php.ini \
;fi
......@@ -427,6 +442,11 @@ RUN echo "" >> ~/.bashrc && \
#####################################
# Laravel Envoy:
#####################################
USER root
RUN apt-get update -yqq \
&& apt-get install -y php-curl
USER laradock
ARG INSTALL_LARAVEL_ENVOY=false
......@@ -442,6 +462,13 @@ RUN if [ ${INSTALL_LARAVEL_ENVOY} = true ]; then \
#####################################
USER root
ARG COMPOSER_REPO_PACKAGIST
ENV COMPOSER_REPO_PACKAGIST ${COMPOSER_REPO_PACKAGIST}
RUN if [ ${COMPOSER_REPO_PACKAGIST} ]; then \
composer config -g repo.packagist composer ${COMPOSER_REPO_PACKAGIST} \
;fi
ARG INSTALL_LARAVEL_INSTALLER=false
ENV INSTALL_LARAVEL_INSTALLER ${INSTALL_LARAVEL_INSTALLER}
......@@ -457,14 +484,18 @@ USER laradock
#####################################
# Deployer:
#####################################
USER laradock
USER root
ARG INSTALL_DEPLOYER=false
ENV INSTALL_DEPLOYER ${INSTALL_DEPLOYER}
RUN if [ ${INSTALL_DEPLOYER} = true ]; then \
# Install the Deployer
composer global require "deployer/deployer" \
# Using Phar as currently there is no support for laravel 4 from composer version
# Waiting to be resolved on https://github.com/deployphp/deployer/issues/1552
curl -LO https://deployer.org/deployer.phar && \
mv deployer.phar /usr/local/bin/dep && \
chmod +x /usr/local/bin/dep \
;fi
#####################################
......@@ -704,6 +735,12 @@ RUN if [ ${INSTALL_DUSK_DEPS} = true ]; then \
&& rm chromedriver_linux64.zip \
;fi
#####################################
# Check PHP version:
#####################################
RUN php -v | head -n 1 | grep -q "PHP 7.1."
#
#--------------------------------------------------------------------------
# Final Touch
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment