Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

undefined method 'keys' error #1

Open
bixu opened this issue Jul 18, 2014 · 0 comments
Open

undefined method 'keys' error #1

bixu opened this issue Jul 18, 2014 · 0 comments

Comments

@bixu
Copy link
Contributor

bixu commented Jul 18, 2014

when i updated my berkshelf to use the 0.5.0 version of the cookbook (from 0.3.0), chef started exploding like this:

================================================================================
Recipe Compile Error in /var/chef/cache/cookbooks/openswan-yetu/recipes/default.rb
================================================================================


NoMethodError
-------------
undefined method `keys' for nil:NilClass


Cookbook Trace:
---------------
  /var/chef/cache/cookbooks/openswan/recipes/_enable_snat.rb:1:in `block in from_file'
  /var/chef/cache/cookbooks/openswan/recipes/_enable_snat.rb:1:in `each'
  /var/chef/cache/cookbooks/openswan/recipes/_enable_snat.rb:1:in `detect'
  /var/chef/cache/cookbooks/openswan/recipes/_enable_snat.rb:1:in `from_file'
  /var/chef/cache/cookbooks/openswan/recipes/l2tp.rb:17:in `from_file'
  /var/chef/cache/cookbooks/openswan/recipes/default.rb:20:in `from_file'
  /var/chef/cache/cookbooks/openswan-yetu/recipes/default.rb:7:in `from_file'


Relevant File Content:
----------------------
/var/chef/cache/cookbooks/openswan/recipes/_enable_snat.rb:

  1>> public_interface = node['network']['interfaces'].detect { |k,v| v['addresses'].keys.include?(node['ipaddress'])}.first
  2:
  3:  execute "turn on public SNAT" do
  4:    command "iptables -t nat -I POSTROUTING -o #{public_interface} -j SNAT --to #{node['ipaddress']}"
  5:    not_if "iptables -L -t nat | grep #{node['ipaddress']}"
  6:    notifies :restart, "service[xl2tpd]"
  7:    notifies :restart, "service[ipsec]"
  8:  end
  9:
 10:  private_interface = node['network']['interfaces'].detect { |k,v| v['addresses'].keys.include?(node['openswan']['private_ip'])}.first



[2014-07-18T12:58:28+00:00] DEBUG: Re-raising exception: NoMethodError - undefined method `keys' for nil:NilClass
/var/chef/cache/cookbooks/openswan/recipes/_enable_snat.rb:1:in `block in from_file'
  /var/chef/cache/cookbooks/openswan/recipes/_enable_snat.rb:1:in `each'
  /var/chef/cache/cookbooks/openswan/recipes/_enable_snat.rb:1:in `detect'
  /var/chef/cache/cookbooks/openswan/recipes/_enable_snat.rb:1:in `from_file'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `instance_eval'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `from_file'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/cookbook_version.rb:237:in `load_recipe'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:165:in `load_recipe'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:134:in `block in include_recipe'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:133:in `each'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:133:in `include_recipe'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/dsl/include_recipe.rb:26:in `include_recipe'
  /var/chef/cache/cookbooks/openswan/recipes/l2tp.rb:17:in `from_file'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `instance_eval'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `from_file'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/cookbook_version.rb:237:in `load_recipe'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:165:in `load_recipe'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:134:in `block in include_recipe'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:133:in `each'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:133:in `include_recipe'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/dsl/include_recipe.rb:26:in `include_recipe'
  /var/chef/cache/cookbooks/openswan/recipes/default.rb:20:in `from_file'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `instance_eval'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `from_file'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/cookbook_version.rb:237:in `load_recipe'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:165:in `load_recipe'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:134:in `block in include_recipe'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:133:in `each'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:133:in `include_recipe'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/dsl/include_recipe.rb:26:in `include_recipe'
  /var/chef/cache/cookbooks/openswan-yetu/recipes/default.rb:7:in `from_file'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `instance_eval'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `from_file'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/cookbook_version.rb:237:in `load_recipe'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:165:in `load_recipe'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context/cookbook_compiler.rb:140:in `block in compile_recipes'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context/cookbook_compiler.rb:138:in `each'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context/cookbook_compiler.rb:138:in `compile_recipes'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context/cookbook_compiler.rb:75:in `compile'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:88:in `load'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/policy_builder/expand_node_object.rb:73:in `setup_run_context'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/client.rb:265:in `setup_run_context'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/client.rb:429:in `do_run'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/client.rb:213:in `block in run'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/client.rb:207:in `fork'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/client.rb:207:in `run'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/application.rb:217:in `run_chef_client'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/application/client.rb:328:in `block in run_application'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/application/client.rb:317:in `loop'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/application/client.rb:317:in `run_application'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/application.rb:67:in `run'
  /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/bin/chef-client:26:in `<top (required)>'
  /usr/local/bin/chef-client:23:in `load'
  /usr/local/bin/chef-client:23:in `<main>'

Running handlers:
[2014-07-18T12:58:28+00:00] ERROR: Running exception handlers
Running handlers complete

[2014-07-18T12:58:28+00:00] ERROR: Exception handlers complete
[2014-07-18T12:58:28+00:00] FATAL: Stacktrace dumped to /var/chef/cache/chef-stacktrace.out
[2014-07-18T12:58:28+00:00] DEBUG: NoMethodError: undefined method `keys' for nil:NilClass
/var/chef/cache/cookbooks/openswan/recipes/_enable_snat.rb:1:in `block in from_file'
/var/chef/cache/cookbooks/openswan/recipes/_enable_snat.rb:1:in `each'
/var/chef/cache/cookbooks/openswan/recipes/_enable_snat.rb:1:in `detect'
/var/chef/cache/cookbooks/openswan/recipes/_enable_snat.rb:1:in `from_file'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `instance_eval'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `from_file'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/cookbook_version.rb:237:in `load_recipe'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:165:in `load_recipe'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:134:in `block in include_recipe'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:133:in `each'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:133:in `include_recipe'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/dsl/include_recipe.rb:26:in `include_recipe'
/var/chef/cache/cookbooks/openswan/recipes/l2tp.rb:17:in `from_file'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `instance_eval'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `from_file'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/cookbook_version.rb:237:in `load_recipe'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:165:in `load_recipe'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:134:in `block in include_recipe'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:133:in `each'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:133:in `include_recipe'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/dsl/include_recipe.rb:26:in `include_recipe'
/var/chef/cache/cookbooks/openswan/recipes/default.rb:20:in `from_file'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `instance_eval'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `from_file'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/cookbook_version.rb:237:in `load_recipe'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:165:in `load_recipe'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:134:in `block in include_recipe'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:133:in `each'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:133:in `include_recipe'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/dsl/include_recipe.rb:26:in `include_recipe'
/var/chef/cache/cookbooks/openswan-yetu/recipes/default.rb:7:in `from_file'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `instance_eval'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `from_file'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/cookbook_version.rb:237:in `load_recipe'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:165:in `load_recipe'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context/cookbook_compiler.rb:140:in `block in compile_recipes'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context/cookbook_compiler.rb:138:in `each'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context/cookbook_compiler.rb:138:in `compile_recipes'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context/cookbook_compiler.rb:75:in `compile'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:88:in `load'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/policy_builder/expand_node_object.rb:73:in `setup_run_context'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/client.rb:265:in `setup_run_context'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/client.rb:429:in `do_run'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/client.rb:213:in `block in run'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/client.rb:207:in `fork'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/client.rb:207:in `run'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/application.rb:217:in `run_chef_client'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/application/client.rb:328:in `block in run_application'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/application/client.rb:317:in `loop'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/application/client.rb:317:in `run_application'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/application.rb:67:in `run'
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/bin/chef-client:26:in `<top (required)>'
/usr/local/bin/chef-client:23:in `load'
/usr/local/bin/chef-client:23:in `<main>'
Chef Client failed. 0 resources updated in 10.586410827 seconds
[2014-07-18T12:58:28+00:00] INFO: Sending resource update report (run-id: 06db94dc-5e15-472b-9f36-c28490a151ad)
[2014-07-18T12:58:28+00:00] DEBUG: {"action"=>"end", "resources"=>[], "status"=>"failure", "run_list"=>"[\"role[base]\",\"role[openswan]\"]", "total_res_count"=>"1", "data"=>{"exception"=>{"class"=>"#<NoMethodError: undefined method `keys' for nil:NilClass>", "message"=>"undefined method `keys' for nil:NilClass", "backtrace"=>"[\"/var/chef/cache/cookbooks/openswan/recipes/_enable_snat.rb:1:in `block in from_file'\",\"/var/chef/cache/cookbooks/openswan/recipes/_enable_snat.rb:1:in `each'\",\"/var/chef/cache/cookbooks/openswan/recipes/_enable_snat.rb:1:in `detect'\",\"/var/chef/cache/cookbooks/openswan/recipes/_enable_snat.rb:1:in `from_file'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `instance_eval'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `from_file'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/cookbook_version.rb:237:in `load_recipe'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:165:in `load_recipe'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:134:in `block in include_recipe'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:133:in `each'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:133:in `include_recipe'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/dsl/include_recipe.rb:26:in `include_recipe'\",\"/var/chef/cache/cookbooks/openswan/recipes/l2tp.rb:17:in `from_file'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `instance_eval'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `from_file'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/cookbook_version.rb:237:in `load_recipe'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:165:in `load_recipe'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:134:in `block in include_recipe'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:133:in `each'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:133:in `include_recipe'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/dsl/include_recipe.rb:26:in `include_recipe'\",\"/var/chef/cache/cookbooks/openswan/recipes/default.rb:20:in `from_file'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `instance_eval'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `from_file'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/cookbook_version.rb:237:in `load_recipe'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:165:in `load_recipe'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:134:in `block in include_recipe'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:133:in `each'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:133:in `include_recipe'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/dsl/include_recipe.rb:26:in `include_recipe'\",\"/var/chef/cache/cookbooks/openswan-yetu/recipes/default.rb:7:in `from_file'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `instance_eval'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/mixin/from_file.rb:30:in `from_file'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/cookbook_version.rb:237:in `load_recipe'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:165:in `load_recipe'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context/cookbook_compiler.rb:140:in `block in compile_recipes'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context/cookbook_compiler.rb:138:in `each'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context/cookbook_compiler.rb:138:in `compile_recipes'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context/cookbook_compiler.rb:75:in `compile'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/run_context.rb:88:in `load'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/policy_builder/expand_node_object.rb:73:in `setup_run_context'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/client.rb:265:in `setup_run_context'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/client.rb:429:in `do_run'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/client.rb:213:in `block in run'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/client.rb:207:in `fork'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/client.rb:207:in `run'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/application.rb:217:in `run_chef_client'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/application/client.rb:328:in `block in run_application'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/application/client.rb:317:in `loop'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/application/client.rb:317:in `run_application'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/lib/chef/application.rb:67:in `run'\",\"/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-11.12.8/bin/chef-client:26:in `<top (required)>'\",\"/usr/local/bin/chef-client:23:in `load'\",\"/usr/local/bin/chef-client:23:in `<main>'\"]", "description"=>{}}}, "start_time"=>"2014-07-18 12:58:23 +0000", "end_time"=>"2014-07-18 12:58:28 +0000"}
[2014-07-18T12:58:28+00:00] DEBUG: Sending compressed run data...
[2014-07-18T12:58:28+00:00] DEBUG: Signing the request as vpn000
[2014-07-18T12:58:28+00:00] DEBUG: String to sign: 'Method:POST
Hashed Path:7r3O7UHmTny16ATk1FlNpo9hIx4=
X-Ops-Content-Hash:aCZtULmRBvOsHiIFupEDq483KPM=
X-Ops-Timestamp:2014-07-18T12:58:28Z
X-Ops-UserId:vpn000'
Header hash: {"X-Ops-Sign"=>"algorithm=sha1;version=1.0;", "X-Ops-Userid"=>"vpn000", "X-Ops-Timestamp"=>"2014-07-18T12:58:28Z", "X-Ops-Content-Hash"=>"aCZtULmRBvOsHiIFupEDq483KPM=", "X-Ops-Authorization-1"=>"Y/oyO+fDMcoS9/Ksi0ANvI7LZqkhd5IL7DmHFrlUuQugrEc/HqhbDhADpADn", "X-Ops-Authorization-2"=>"sRcNKNAA3UrO6eZQCAw9nYzQozzVkzcptk0ZHHY4kwLMQRzWAaUZiUZguYHK", "X-Ops-Authorization-3"=>"UlIqB92vEDBdL7Rk15HE/ANNiEW6L6hI28RGbPcoFkE0p+yNo1d1Baf1sYm9", "X-Ops-Authorization-4"=>"vlwxl29bOxpoby5lyAirg3QxrIqLzqjEDXF8bYametkY6rvdI07nkoS2Vr7e", "X-Ops-Authorization-5"=>"Dy0Sx0T7OypuiEmHJ8lknaCo9IrRbYcShUmFpUfDquno0P+Y4MqrzqwhFpst", "X-Ops-Authorization-6"=>"PcRisws5mlQ8dUiGJZzhqeCz9RO5YbkQ2GIsbI+qAQ=="}
[2014-07-18T12:58:28+00:00] DEBUG: Initiating POST to https://api.opscode.com/organizations/yetu/reports/nodes/vpn000/runs/06db94dc-5e15-472b-9f36-c28490a151ad
[2014-07-18T12:58:28+00:00] DEBUG: ---- HTTP Request Header Data: ----
[2014-07-18T12:58:28+00:00] DEBUG: X-Ops-Reporting-Protocol-Version: 0.1.0
[2014-07-18T12:58:28+00:00] DEBUG: Content-Encoding: gzip
[2014-07-18T12:58:28+00:00] DEBUG: X-OPS-SIGN: algorithm=sha1;version=1.0;
[2014-07-18T12:58:28+00:00] DEBUG: X-OPS-USERID: vpn000
[2014-07-18T12:58:28+00:00] DEBUG: X-OPS-TIMESTAMP: 2014-07-18T12:58:28Z
[2014-07-18T12:58:28+00:00] DEBUG: X-OPS-CONTENT-HASH: aCZtULmRBvOsHiIFupEDq483KPM=
[2014-07-18T12:58:28+00:00] DEBUG: X-OPS-AUTHORIZATION-1: Y/oyO+fDMcoS9/Ksi0ANvI7LZqkhd5IL7DmHFrlUuQugrEc/HqhbDhADpADn
[2014-07-18T12:58:28+00:00] DEBUG: X-OPS-AUTHORIZATION-2: sRcNKNAA3UrO6eZQCAw9nYzQozzVkzcptk0ZHHY4kwLMQRzWAaUZiUZguYHK
[2014-07-18T12:58:28+00:00] DEBUG: X-OPS-AUTHORIZATION-3: UlIqB92vEDBdL7Rk15HE/ANNiEW6L6hI28RGbPcoFkE0p+yNo1d1Baf1sYm9
[2014-07-18T12:58:28+00:00] DEBUG: X-OPS-AUTHORIZATION-4: vlwxl29bOxpoby5lyAirg3QxrIqLzqjEDXF8bYametkY6rvdI07nkoS2Vr7e
[2014-07-18T12:58:28+00:00] DEBUG: X-OPS-AUTHORIZATION-5: Dy0Sx0T7OypuiEmHJ8lknaCo9IrRbYcShUmFpUfDquno0P+Y4MqrzqwhFpst
[2014-07-18T12:58:28+00:00] DEBUG: X-OPS-AUTHORIZATION-6: PcRisws5mlQ8dUiGJZzhqeCz9RO5YbkQ2GIsbI+qAQ==
[2014-07-18T12:58:28+00:00] DEBUG: HOST: api.opscode.com:443
[2014-07-18T12:58:28+00:00] DEBUG: X-REMOTE-REQUEST-ID: 06db94dc-5e15-472b-9f36-c28490a151ad
[2014-07-18T12:58:28+00:00] DEBUG: Content-Length: 730
[2014-07-18T12:58:28+00:00] DEBUG: ---- End HTTP Request Header Data ----
[2014-07-18T12:58:30+00:00] DEBUG: ---- HTTP Status and Header Data: ----
[2014-07-18T12:58:30+00:00] DEBUG: HTTP 1.1 200 OK
[2014-07-18T12:58:30+00:00] DEBUG: server: ngx_openresty
[2014-07-18T12:58:30+00:00] DEBUG: date: Fri, 18 Jul 2014 12:58:30 GMT
[2014-07-18T12:58:30+00:00] DEBUG: content-type: application/json
[2014-07-18T12:58:30+00:00] DEBUG: content-length: 2
[2014-07-18T12:58:30+00:00] DEBUG: connection: close
[2014-07-18T12:58:30+00:00] DEBUG: ---- End HTTP Status/Header Data ----
[2014-07-18T12:58:30+00:00] ERROR: undefined method `keys' for nil:NilClass
[2014-07-18T12:58:30+00:00] FATAL: Chef::Exceptions::ChildConvergeError: Chef run process exited unsuccessfully (exit code 1)

Happy to do a PR if you guys can point me in the right direction. No one at $job is a ruby expert :(

@sax @hjhart @kig

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant