From bb284756b22dbfde5585cfb72ca547a702122b16 Mon Sep 17 00:00:00 2001 From: louisbl Date: Thu, 23 Apr 2015 16:37:12 +0200 Subject: [PATCH] Add php5.4 versions --- 5.4/apache/Dockerfile | 35 +++++++++++++++++++++++++++++++++++ 5.4/cli/Dockerfile | 38 ++++++++++++++++++++++++++++++++++++++ 5.4/fpm/Dockerfile | 37 +++++++++++++++++++++++++++++++++++++ 5.4/fpm/php-fpm.conf | 25 +++++++++++++++++++++++++ 4 files changed, 135 insertions(+) create mode 100644 5.4/apache/Dockerfile create mode 100644 5.4/cli/Dockerfile create mode 100644 5.4/fpm/Dockerfile create mode 100644 5.4/fpm/php-fpm.conf diff --git a/5.4/apache/Dockerfile b/5.4/apache/Dockerfile new file mode 100644 index 0000000..5fb44d0 --- /dev/null +++ b/5.4/apache/Dockerfile @@ -0,0 +1,35 @@ +FROM php:5.4-apache +MAINTAINER louisbl + +ENV DEBIAN_FRONTEND noninteractive + +RUN apt-get update && apt-get install -y --no-install-recommends \ + bzip2 \ + g++ \ + libbz2-dev \ + libcurl4-openssl-dev \ + libfreetype6-dev \ + libicu-dev \ + libjpeg62-turbo-dev \ + libmcrypt-dev \ + libpng12-dev \ + libpq-dev \ + libreadline6-dev \ + libssl-dev \ + libxml2-dev \ + libzip-dev \ + zlib1g-dev \ + && rm -rf /var/lib/apt/lists/* + +RUN docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-gd-dir=/usr/include/ \ + && docker-php-ext-install \ + bz2 \ + gd \ + intl \ + mbstring \ + mcrypt \ + mysqli \ + pdo_mysql \ + pdo_pgsql \ + pgsql \ + zip diff --git a/5.4/cli/Dockerfile b/5.4/cli/Dockerfile new file mode 100644 index 0000000..2205af9 --- /dev/null +++ b/5.4/cli/Dockerfile @@ -0,0 +1,38 @@ +FROM php:5.4-cli +MAINTAINER louisbl + +ENV DEBIAN_FRONTEND noninteractive + +RUN apt-get update && apt-get install -y --no-install-recommends \ + bzip2 \ + g++ \ + libbz2-dev \ + libcurl4-openssl-dev \ + libfreetype6-dev \ + libicu-dev \ + libjpeg62-turbo-dev \ + libmcrypt-dev \ + libpng12-dev \ + libpq-dev \ + libreadline6-dev \ + libssl-dev \ + libxml2-dev \ + libzip-dev \ + zlib1g-dev \ + && rm -rf /var/lib/apt/lists/* + +RUN docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-gd-dir=/usr/include/ \ + && docker-php-ext-install \ + bz2 \ + gd \ + intl \ + mbstring \ + mcrypt \ + mysqli \ + pdo_mysql \ + pdo_pgsql \ + pgsql \ + zip + +RUN mkdir -p /var/www/html && chown -R www-data:www-data /var/www/html +WORKDIR /var/www/html diff --git a/5.4/fpm/Dockerfile b/5.4/fpm/Dockerfile new file mode 100644 index 0000000..db9ef24 --- /dev/null +++ b/5.4/fpm/Dockerfile @@ -0,0 +1,37 @@ +FROM php:5.4-fpm +MAINTAINER louisbl + +ENV DEBIAN_FRONTEND noninteractive + +RUN apt-get update && apt-get install -y --no-install-recommends \ + bzip2 \ + g++ \ + libbz2-dev \ + libcurl4-openssl-dev \ + libfreetype6-dev \ + libicu-dev \ + libjpeg62-turbo-dev \ + libmcrypt-dev \ + libpng12-dev \ + libpq-dev \ + libreadline6-dev \ + libssl-dev \ + libxml2-dev \ + libzip-dev \ + zlib1g-dev \ + && rm -rf /var/lib/apt/lists/* + +RUN docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-gd-dir=/usr/include/ \ + && docker-php-ext-install \ + bz2 \ + gd \ + intl \ + mbstring \ + mcrypt \ + mysqli \ + pdo_mysql \ + pdo_pgsql \ + pgsql \ + zip + +COPY php-fpm.conf /usr/local/etc/php-fpm.conf diff --git a/5.4/fpm/php-fpm.conf b/5.4/fpm/php-fpm.conf new file mode 100644 index 0000000..553a46b --- /dev/null +++ b/5.4/fpm/php-fpm.conf @@ -0,0 +1,25 @@ +[global] + +error_log = /proc/self/fd/2 +daemonize = no + +[www] + +; if we send this to /proc/self/fd/1, it never appears +access.log = /proc/self/fd/2 + +user = www-data +group = www-data + +listen = [::]:9000 + +pm = dynamic +pm.max_children = 5 +pm.start_servers = 2 +pm.min_spare_servers = 1 +pm.max_spare_servers = 3 + +clear_env = false + +catch_workers_output = yes +php_flag[log_errors] = on