From 462cd1b862396a870ef490e9a830f6287f15af1b Mon Sep 17 00:00:00 2001 From: Nhan Nguyen Date: Wed, 29 Apr 2015 10:20:52 +0700 Subject: [PATCH] allow changing php memory_limit --- php/attributes/default.rb | 1 + php/templates/default/php.ini.erb | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/php/attributes/default.rb b/php/attributes/default.rb index 1fd6d3e..e4309cf 100644 --- a/php/attributes/default.rb +++ b/php/attributes/default.rb @@ -26,6 +26,7 @@ default[:php][:upload_max_filesize] = "2M" default[:php][:max_execution_time] = 30 default[:php][:max_file_uploads] = 20 +default[:php][:memory_limit] = "128M" default[:php][:error_reporting] = 'E_ALL & ~E_DEPRECATED' default[:php][:fpm][:catch_workers_output] = 'yes' diff --git a/php/templates/default/php.ini.erb b/php/templates/default/php.ini.erb index c7428cc..35a2a3d 100644 --- a/php/templates/default/php.ini.erb +++ b/php/templates/default/php.ini.erb @@ -22,7 +22,7 @@ disable_classes = expose_php = Off max_execution_time = <%= php[:max_execution_time] %> max_input_time = 60 -memory_limit = 128M +memory_limit = <%= php[:memory_limit] %> error_reporting = <%= php[:error_reporting] %> display_errors = Off display_startup_errors = Off