From 9b73d0d55e34f0025a368b30c49ca355aedc02da Mon Sep 17 00:00:00 2001 From: Hardware Date: Mon, 18 Jul 2016 07:55:59 +0200 Subject: [PATCH] perf(): improve performances with opcache extension --- Dockerfile | 2 ++ opcache.ini | 8 ++++++++ 2 files changed, 10 insertions(+) create mode 100644 opcache.ini diff --git a/Dockerfile b/Dockerfile index de4ac84..58a3e30 100644 --- a/Dockerfile +++ b/Dockerfile @@ -22,6 +22,7 @@ RUN echo "@testing https://nl.alpinelinux.org/alpine/edge/testing" >> /etc/apk/r php7-dom@testing \ php7-ctype@testing \ php7-session@testing \ + php7-opcache@testing \ && cd /tmp \ && ln -s /usr/bin/php7 /usr/bin/php \ && curl -s http://getcomposer.org/installer | php \ @@ -37,6 +38,7 @@ RUN echo "@testing https://nl.alpinelinux.org/alpine/edge/testing" >> /etc/apk/r COPY config.sql /flarum/app/config.sql COPY nginx.conf /etc/nginx/nginx.conf COPY php-fpm.conf /etc/php7/php-fpm.conf +COPY opcache.ini /etc/php7/conf.d/00_opcache.ini COPY supervisord.conf /etc/supervisor/supervisord.conf COPY startup /usr/local/bin/startup diff --git a/opcache.ini b/opcache.ini new file mode 100644 index 0000000..861ea15 --- /dev/null +++ b/opcache.ini @@ -0,0 +1,8 @@ +zend_extension=opcache.so +opcache.enable=1 +opcache.enable_cli=1 +opcache.fast_shutdown=1 +opcache.memory_consumption=128 +opcache.interned_strings_buffer=16 +opcache.max_accelerated_files=5413 +opcache.revalidate_freq=60