From ff78508cf1ef68bb412a070ea338692b88b89a6b Mon Sep 17 00:00:00 2001 From: Frank Febbraro Date: Mon, 10 Apr 2017 15:13:59 -0700 Subject: [PATCH 1/3] ignore file --- .gitignore | 1 + 1 file changed, 1 insertion(+) create mode 100644 .gitignore diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..bfa6a22 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +# Created by .ignore support plugin (hsz.mobi) From a599e39dcf241e9e32a0871943af06a43b0cd85c Mon Sep 17 00:00:00 2001 From: Frank Febbraro Date: Mon, 10 Apr 2017 15:14:26 -0700 Subject: [PATCH 2/3] Fix path to php session to be version agnostic --- .gitignore | 2 +- Dockerfile | 2 ++ root/etc/confd/templates/www.conf.tmpl | 3 +-- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index bfa6a22..485dee6 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1 @@ -# Created by .ignore support plugin (hsz.mobi) +.idea diff --git a/Dockerfile b/Dockerfile index 6396c6f..79131f7 100644 --- a/Dockerfile +++ b/Dockerfile @@ -7,6 +7,8 @@ RUN yum -y install \ EXPOSE 80 +RUN mkdir -p /var/lib/php/session + COPY root / VOLUME ["/var/log/httpd"] diff --git a/root/etc/confd/templates/www.conf.tmpl b/root/etc/confd/templates/www.conf.tmpl index 2e3fc62..70d621d 100644 --- a/root/etc/confd/templates/www.conf.tmpl +++ b/root/etc/confd/templates/www.conf.tmpl @@ -217,7 +217,6 @@ catch_workers_output = yes ; specified at startup with the -d argument ;php_admin_value[sendmail_path] = /usr/sbin/sendmail -t -i -f www@my.domain.com php_flag[display_errors] = off -;php_admin_value[error_log] = /opt/rh/php55/root/var/log/php-fpm/www-error.log php_admin_flag[log_errors] = on php_value[max_execution_time] = {{getenv "PHP_MAX_EXECUTION_TIME"}} php_value[memory_limit] = {{getenv "PHP_MEMORY_LIMIT"}} @@ -228,7 +227,7 @@ php_value[upload_max_filesize] = {{getenv "PHP_UPLOAD_MAX_FILESIZE"}} ; Set session path to a directory owned by process user php_value[session.save_handler] = files -php_value[session.save_path] = /opt/rh/php55/root/var/lib/php/session +php_value[session.save_path] = /var/lib/php/session ; Pass the full ENV through. clear_env = false From 44caceb331a7f1891ea922f4de314d47093e9e66 Mon Sep 17 00:00:00 2001 From: Frank Febbraro Date: Tue, 11 Apr 2017 09:17:59 -0700 Subject: [PATCH 3/3] Added the session directory as an explicit volume --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 79131f7..e8e7996 100644 --- a/Dockerfile +++ b/Dockerfile @@ -11,7 +11,7 @@ RUN mkdir -p /var/lib/php/session COPY root / -VOLUME ["/var/log/httpd"] +VOLUME ["/var/log/httpd", "/var/lib/php/session"] ENV PROXY_TIMEOUT 120 ENV PHP_MAX_EXECUTION_TIME 60