There is no separate rubygems or irb for ruby 1.9 and later
authorTom Hughes <tom@compton.nu>
Fri, 20 Feb 2015 16:08:30 +0000 (16:08 +0000)
committerTom Hughes <tom@compton.nu>
Fri, 20 Feb 2015 16:18:37 +0000 (16:18 +0000)
cookbooks/passenger/recipes/default.rb
cookbooks/web/definitions/rails_port.rb

index 267942f..229281c 100644 (file)
@@ -21,8 +21,11 @@ include_recipe "apache"
 
 package "ruby#{node[:passenger][:ruby_version]}"
 package "ruby#{node[:passenger][:ruby_version]}-dev"
-package "rubygems#{node[:passenger][:ruby_version]}"
-package "irb#{node[:passenger][:ruby_version]}"
+
+if node[:passenger][:ruby_version].to_f < 1.9
+  package "rubygems#{node[:passenger][:ruby_version]}"
+  package "irb#{node[:passenger][:ruby_version]}"
+end
 
 template "/usr/local/bin/passenger-ruby" do
   source "ruby.erb"
index a072a88..205695c 100644 (file)
@@ -40,8 +40,8 @@ define :rails_port, :action => [:create, :enable] do
 
   package "ruby#{ruby_version}"
   package "ruby#{ruby_version}-dev"
-  package "rubygems#{ruby_version}"
-  package "irb#{ruby_version}"
+  package "rubygems#{ruby_version}" if ruby_version.to_f < 1.9
+  package "irb#{ruby_version}" if ruby_version.to_f < 1.9
   package "imagemagick"
   package "nodejs"