Skip to content

Commit

Permalink
Use minimum php version by default
Browse files Browse the repository at this point in the history
  • Loading branch information
nWidart committed Sep 9, 2017
1 parent d6dca69 commit cb0df01
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 19 deletions.
30 changes: 15 additions & 15 deletions docker/app/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -16,19 +16,19 @@ RUN add-apt-repository ppa:nginx/stable \
&& apt-get update \
&& apt-get install --no-install-recommends -y \
nginx \
php7.1-fpm \
php7.1-cli \
php7.1-xdebug \
php7.1-pdo \
php7.1-pdo-mysql \
php7.1-sqlite3 \
php7.1-xml \
php7.1-mbstring \
php7.1-tokenizer \
php7.1-zip \
php7.1-mcrypt \
php7.1-gd \
php7.1-curl \
php7.0-fpm \
php7.0-cli \
php7.0-xdebug \
php7.0-pdo \
php7.0-pdo-mysql \
php7.0-sqlite3 \
php7.0-xml \
php7.0-mbstring \
php7.0-tokenizer \
php7.0-zip \
php7.0-mcrypt \
php7.0-gd \
php7.0-curl \
curl \
&& mkdir /run/php \
&& curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer \
Expand All @@ -38,7 +38,7 @@ RUN add-apt-repository ppa:nginx/stable \
&& rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*

COPY default /etc/nginx/sites-enabled/default
COPY php-fpm.conf /etc/php/7.1/fpm/php-fpm.conf
COPY php-fpm.conf /etc/php/7.0/fpm/php-fpm.conf
COPY supervisord.conf /etc/supervisor/conf.d/supervisord.conf

RUN mkdir /tmp/certgen
Expand All @@ -57,4 +57,4 @@ RUN openssl genrsa -des3 -passout pass:x -out server.pass.key 2048 \
EXPOSE 80
EXPOSE 443

CMD ["supervisord"]
CMD ["supervisord"]
2 changes: 1 addition & 1 deletion docker/app/default
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ server {
}
location ~ \.php$ {
include snippets/fastcgi-php.conf;
fastcgi_pass unix:/run/php/php7.1-fpm.sock;
fastcgi_pass unix:/run/php/php7.0-fpm.sock;
}
location ~ /\.ht {
deny all;
Expand Down
4 changes: 2 additions & 2 deletions docker/app/php-fpm.conf
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
; Pid file
; Note: the default prefix is /var
; Default Value: none
pid = /run/php/php7.1-fpm.pid
pid = /run/php/php7.0-fpm.pid

; Error log file
; If it's set to "syslog", log is sent to syslogd instead of being written
Expand Down Expand Up @@ -122,4 +122,4 @@ daemonize = no
; Relative path can also be used. They will be prefixed by:
; - the global prefix if it's been set (-p argument)
; - /usr otherwise
include=/etc/php/7.1/fpm/pool.d/*.conf
include=/etc/php/7.0/fpm/pool.d/*.conf
2 changes: 1 addition & 1 deletion docker/app/supervisord.conf
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ stderr_logfile=/dev/stderr
stderr_logfile_maxbytes=0

[program:php-fpm]
command=php-fpm7.1
command=php-fpm7.0
stdout_logfile=/dev/stdout
stdout_logfile_maxbytes=0
stderr_logfile=/dev/stderr
Expand Down

0 comments on commit cb0df01

Please sign in to comment.