From 2f5c06d08c5a2fcc42d57896ba7151bee326f7ac Mon Sep 17 00:00:00 2001 From: Tom Hughes Date: Fri, 20 Feb 2015 16:44:52 +0000 Subject: [PATCH] Update ruby tuning for ruby 2.1 --- cookbooks/passenger/templates/default/ruby.erb | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/cookbooks/passenger/templates/default/ruby.erb b/cookbooks/passenger/templates/default/ruby.erb index 4d962204e..fb7575ab0 100644 --- a/cookbooks/passenger/templates/default/ruby.erb +++ b/cookbooks/passenger/templates/default/ruby.erb @@ -1,7 +1,12 @@ #!/bin/sh +<% if node[:passenger][:ruby_version].to_f < 2.1 -%> export RUBY_HEAP_MIN_SLOTS=500000 export RUBY_HEAP_FREE_MIN=100000 +<% else -%> +export RUBY_GC_HEAP_INIT_SLOTS=500000 +export RUBY_GC_HEAP_FREE_SLOTS=100000 +<% end -%> export RUBY_GC_MALLOC_LIMIT=50000000 exec /usr/bin/ruby<%= node[:passenger][:ruby_version] %> "$@" -- 2.39.5