[chef] recipe[chef-server::apache-proxy] String vs Symbol Dictonary Keys


Chronological Thread 
  • From: Chris McClimans < >
  • To:
  • Subject: [chef] recipe[chef-server::apache-proxy] String vs Symbol Dictonary Keys
  • Date: Wed, 10 Aug 2011 17:43:20 +1200

Given a chef-solo run "run_list": [ "recipe[chef-server::rubygems-install]", "recipe[chef-server::apache-proxy]" ]  #https://gist.github.com/1136193

chef-server/templates/default/chef_server.conf.erb:4
-  ServerAlias <% @params['server_aliases'].each do |a| %><%= "#{a}" %> <% end %>

Fails because the string 'server_aliases' returns nil, while the Symbol :server_aliases returns the correct values.

So I made changes here:

https://github.com/hh/cookbooks/commit/495255688be0f286d8c08215f2e5f95c2f18d775#L0L3

The web_app is defined here:

https://github.com/hh/cookbooks/blob/495255688be0f286d8c08215f2e5f95c2f18d775/chef-server/recipes/apache-proxy.rb#L58

Is there a better way to get around this error... I'd assume the opscode repo for apache-proxy is correct, and my ruby-foo is a bit weak.

Help?
Cheers,
-chris


  • [chef] recipe[chef-server::apache-proxy] String vs Symbol Dictonary Keys, Chris McClimans, 08/09/2011

Archive powered by MHonArc 2.6.16.

§