diff --git a/docker/phprun.ini b/docker/phprun.ini deleted file mode 100644 index 3bff4f3..0000000 --- a/docker/phprun.ini +++ /dev/null @@ -1,18 +0,0 @@ -; 内存不限制 -memory_limit = -1 - -; 上传文件大小不限制 -upload_max_filesize = -1 - -; 运行时长不限制 -max_execution_time = 0 - -; POST大小不限制 -post_max_size = -1 - -; 进程数不限制 -pm = dynamic -pm.max_children = 150 -pm.start_servers = 10 -pm.min_spare_servers = 10 -pm.max_spare_servers = 30 \ No newline at end of file diff --git a/docker/run.sh b/docker/run.sh index 66cd005..b2aa688 100644 --- a/docker/run.sh +++ b/docker/run.sh @@ -5,7 +5,9 @@ cp /var/www/html/docker/nginx.conf /etc/nginx/sites-available/default ln -s /etc/nginx/sites-available/default /etc/nginx/sites-enabled/default # 将代码中的php配置文件复制到php配置文件中 -cp /var/www/html/docker/phprun.ini /usr/local/etc/php/conf.d +cp /var/www/html/docker/zz-phprun.ini /usr/local/etc/php/conf.d +cp /var/www/html/docker/zz-phpfpm.conf /usr/local/etc/php-fpm.d + # 运行redis nohup redis-server --requirepass "" & @@ -22,4 +24,4 @@ if [ "$1" = "server" ] || [ "$1" = "" ]; then php-fpm else php "/var/www/html/""$@" -fi +fi \ No newline at end of file diff --git a/docker/zz-phpfpm.conf b/docker/zz-phpfpm.conf new file mode 100644 index 0000000..a145c68 --- /dev/null +++ b/docker/zz-phpfpm.conf @@ -0,0 +1,8 @@ + +[www] +; 进程数不限制 +pm = dynamic +pm.max_children = 150 +pm.start_servers = 10 +pm.min_spare_servers = 10 +pm.max_spare_servers = 30 \ No newline at end of file diff --git a/docker/zz-phprun.ini b/docker/zz-phprun.ini new file mode 100644 index 0000000..ee9b41c --- /dev/null +++ b/docker/zz-phprun.ini @@ -0,0 +1,24 @@ +; 内存不限制 +memory_limit = -1 + +; 上传文件大小不限制 +upload_max_filesize = -1 + +; 运行时长不限制 +max_execution_time = 0 + +; POST大小不限制 +post_max_size = -1 + + + +[Zend Opcache] +opcache.enable = 1 +opcache.memory_consumption=128 +opcache.interned_strings_buffer=32 +opcache.max_accelerated_files=80000 +opcache.revalidate_freq=3 +opcache.fast_shutdown=1 +opcache.enable_cli=1 +opcache.jit_buffer_size=128m +opcache.jit=1205 \ No newline at end of file