Skip to content
Browse files

Receipes grab data from environment-specific node file

  • Loading branch information...
1 parent d633822 commit e60308dfdee2e1d816615ac41016cf88ceffcdb3 @ffomenko committed Jun 28, 2012
Showing with 15 additions and 3 deletions.
  1. +8 −0 config/production.json
  2. +7 −3 cookbooks/main/recipes/default.rb
View
8 config/production.json
@@ -0,0 +1,8 @@
+{
+ "recipes": [ "main" ],
+ "rails_env" : "production",
+ "deploy_user" : "deploy",
+ "server_name" : "web1.prod1.liferisksv2.rms.com",
+ "app_root" : "/var/www/Test"
+}
+
View
10 cookbooks/main/recipes/default.rb
@@ -16,8 +16,12 @@
mode 0600
end
+directory node[:app_root] do
+ owner node[:deploy_user]
+end
+
web_app "liferisks" do
- docroot "/var/www/Test/current"
- server_name "web1.prod1.liferisksv2.rms.com"
- rails_env "production"
+ docroot "#{node[:app_root]}/current/public"
+ server_name node[:server_name]
+ rails_env node[:rails_env]
end

0 comments on commit e60308d

Please sign in to comment.
Something went wrong with that request. Please try again.