2014-03-02 2 views
0

Предупреждения: Я только начал изучать Chef так что следующая ошибка может быть весьма тривиальной :(Opsworks пользовательские рецепт терпит неудачу с питоном :: пип

Я провел последние три дня, пытаясь выяснить следующее, но до сих пор я гавань

Я пытаюсь установить новый агент python Relic внутри слоя веб-сервера нашего оппонента. Новая кулинарная книга Relic (https://github.com/escapestudios-cookbooks/newrelic) требует кулинарной книги python который я добавил (https://github.com/poise/python). Однако, что бы я ни делал, пакет не будет устанавливаться из-за неопределенных методов внутри рецептов. Затем я подумал, что эта кулинарная книга python может быть несовместима с Amazon (не указан в качестве платформы), и поэтому я попробовал дюжину других кулинарных книг.

Я изменил рецепты и все еще ничего - что бы я ни делал, не работает.

Вот самый очевидный журнал ошибок при попытке запустить рецепт New Relic с питона поваренной книги:

Opsworks Платформа: Amazon AMI 2013-9 с питон, питон-пип и питона-разви установлен.

New Relic рецепт:

#install latest python agent 
python_pip "newrelic" do 
    action :install 
    if node['newrelic']['python_version'] != "latest" 
     version node['newrelic']['python_version'] 
    end 
end 

Журнал ошибок

... 
    /opt/aws/opsworks/releases/20140211150717_220/cookbooks/opsworks_cleanup/attributes/default.rb 

    [2014-03-02T01:00:31+00:00] DEBUG: Loading Recipe python::pip via include_recipe 
    [2014-03-02T01:00:31+00:00] DEBUG: Found recipe pip in cookbook python 
    [2014-03-02T01:00:31+00:00] DEBUG: filtered backtrace of compile error: 
    [2014-03-02T01:00:31+00:00] DEBUG: filtered backtrace of compile error: 
    [2014-03-02T01:00:31+00:00] DEBUG: backtrace entry for compile error: '/opt/aws/opsworks/releases/20140211150717_220/site-cookbooks/python/recipes/pip.rb:26:in `from_file'' 
    [2014-03-02T01:00:31+00:00] DEBUG: Line number of compile error: '26' 

    ================================================================================ 
    Recipe Compile Error in /opt/aws/opsworks/releases/20140211150717_220/site-cookbooks/newrelic/recipes/python-agent.rb 
    ================================================================================ 


    NoMethodError 
    ------------- 
    undefined method `[]' for nil:NilClass 


    Cookbook Trace: 
    --------------- 
    /opt/aws/opsworks/releases/20140211150717_220/site-cookbooks/python/recipes/pip.rb:26:in `from_file' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/cookbook_version.rb:346:in `load_recipe' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:151:in `load_recipe' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:132:in `include_recipe' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:131:in `each' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:131:in `include_recipe' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/dsl/include_recipe.rb:26:in `include_recipe' 
    /opt/aws/opsworks/releases/20140211150717_220/site-cookbooks/newrelic/recipes/python-agent.rb:8:in `from_file' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/cookbook_version.rb:346:in `load_recipe' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:151:in `load_recipe' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:139:in `compile_recipes' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:137:in `each' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:137:in `compile_recipes' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:74:in `compile' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:86:in `load' 
    /opt/aws/opsworks/releases/20140211150717_220/cookbooks/opsworks_custom_cookbooks/recipes/execute.rb:15:in `from_file' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/provider/ruby_block.rb:33:in `call' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/provider/ruby_block.rb:33:in `action_run' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/mixin/why_run.rb:52:in `call' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/mixin/why_run.rb:52:in `add_action' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/provider.rb:151:in `converge_by' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/provider/ruby_block.rb:32:in `action_run' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/provider.rb:114:in `send' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/provider.rb:114:in `run_action' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/resource.rb:617:in `run_action' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/runner.rb:50:in `run_action' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/runner.rb:82:in `converge' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/runner.rb:82:in `each' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/runner.rb:82:in `converge' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/resource_collection.rb:94:in `execute_each_resource' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/resource_collection/stepable_iterator.rb:116:in `call' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/resource_collection/stepable_iterator.rb:116:in `call_iterator_block' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/resource_collection/stepable_iterator.rb:85:in `step' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/resource_collection/stepable_iterator.rb:104:in `iterate' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/resource_collection/stepable_iterator.rb:55:in `each_with_index' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/resource_collection.rb:92:in `execute_each_resource' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/runner.rb:81:in `converge' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/client.rb:404:in `converge' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/client.rb:469:in `do_run' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/client.rb:200:in `run' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/application.rb:190:in `run_chef_client' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/application/solo.rb:239:in `run_application' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/application/solo.rb:231:in `loop' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/application/solo.rb:231:in `run_application' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/application.rb:73:in `run' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/chef-solo:25 
    /opt/aws/opsworks/current/bin/chef-solo:16:in `load' 
    /opt/aws/opsworks/current/bin/chef-solo:16 


    Relevant File Content: 
    ---------------------- 
    /opt/aws/opsworks/releases/20140211150717_220/site-cookbooks/python/recipes/pip.rb: 

    19: # 
    20: 
    21: # Where does pip get installed? 
    22: # platform/method: path (proof) 
    23: # redhat/package: /usr/bin/pip (sha a8a3a3) 
    24: # omnibus/source: /opt/local/bin/pip (sha 29ce9874) 
    25: 
    26>> if node['python']['install_method'] == 'source' 
    27: pip_binary = "#{node['python']['prefix_dir']}/bin/pip" 
    28: elsif platform_family?("rhel", "fedora") 
    29: pip_binary = "/usr/bin/pip" 
    30: elsif platform_family?("smartos") 
    31: pip_binary = "/opt/local/bin/pip" 
    32: else 
    33: pip_binary = "/usr/local/bin/pip" 
    34: end 
    35: 



    [2014-03-02T01:00:32+00:00] ERROR: Caught exception while compiling OpsWorks custom run list: NoMethodError - undefined method `[]' for nil:NilClass - /opt/aws/opsworks/releases/20140211150717_220/site-cookbooks/python/recipes/pip.rb:26:in `from_file' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/cookbook_version.rb:346:in `load_recipe' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:151:in `load_recipe' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:132:in `include_recipe' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:131:in `each' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:131:in `include_recipe' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/dsl/include_recipe.rb:26:in `include_recipe' 
    /opt/aws/opsworks/releases/20140211150717_220/site-cookbooks/newrelic/recipes/python-agent.rb:8:in `from_file' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/cookbook_version.rb:346:in `load_recipe' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:151:in `load_recipe' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:139:in `compile_recipes' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:137:in `each' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:137:in `compile_recipes' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:74:in `compile' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:86:in `load' 
    /opt/aws/opsworks/releases/20140211150717_220/cookbooks/opsworks_custom_cookbooks/recipes/execute.rb:15:in `from_file' 
    /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/provider/ruby_block.rb:33:in `call' 
    ... 
11.4.4/bin/../lib/chef/resource_collection/stepable_iterator.rb:85:in `step' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/resource_collection/stepable_iterator.rb:104:in `iterate' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/resource_collection/stepable_iterator.rb:55:in `each_with_index' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/resource_collection.rb:92:in `execute_each_resource' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/runner.rb:81:in `converge' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/client.rb:404:in `converge' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/client.rb:469:in `do_run' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/client.rb:200:in `run' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/application.rb:190:in `run_chef_client' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/application/solo.rb:239:in `run_application' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/application/solo.rb:231:in `loop' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/application/solo.rb:231:in `run_application' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/application.rb:73:in `run' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/chef-solo:25 
     /opt/aws/opsworks/current/bin/chef-solo:16:in `load' 
     /opt/aws/opsworks/current/bin/chef-solo:16 

     ================================================================================ 
     Error executing action `run` on resource 'ruby_block[Compile Custom OpsWorks Run List]' 
     ================================================================================ 


     NoMethodError 
     ------------- 
     undefined method `[]' for nil:NilClass 


     Resource Declaration: 
     --------------------- 
     # In /opt/aws/opsworks/releases/20140211150717_220/cookbooks/opsworks_custom_cookbooks/recipes/execute.rb 

     3: ruby_block("Compile Custom OpsWorks Run List") do 
     4: block do 
     5:  begin 
     6: 
     7:  # Reload cookbooks after they're available on local filesystem 
     8:  cl = Chef::CookbookLoader.new(Chef::Config[:cookbook_path]) 
     9:  cl.load_cookbooks 
     10:  self.run_context.instance_variable_set(:@cookbook_collection, Chef::CookbookCollection.new(cl)) 
     11: 
     12:  # Expand run list with custom cookbooks and load them into the current run_context 
     13:  opsworks_run_list = Chef::RunList.new(*node[:opsworks_custom_cookbooks][:recipes]) 
     14:  Chef::Log.info "New Run List expands to #{opsworks_run_list.run_list_items.map(&:name).inspect}" 
     15:  self.run_context.load(opsworks_run_list) 
     16: 
     17:  rescue Exception => e 
     18:  Chef::Log.error "Caught exception while compiling OpsWorks custom run list: #{e.class} - #{e.message} - #{e.backtrace.join("\n")}" 
     19:  raise e 
     20:  end 
     21: 
     22: end 
     23: end 



     Compiled Resource: 
     ------------------ 
     # Declared in /opt/aws/opsworks/releases/20140211150717_220/cookbooks/opsworks_custom_cookbooks/recipes/execute.rb:3:in `from_file' 

     ruby_block("Compile Custom OpsWorks Run List") do 
     block_name "Compile Custom OpsWorks Run List" 
     retry_delay 2 
     cookbook_name :opsworks_custom_cookbooks 
     retries 0 
     block #<Proc:[email protected]/opt/aws/opsworks/releases/20140211150717_220/cookbooks/opsworks_custom_cookbooks/recipes/execute.rb:4> 
     recipe_name "execute" 
     action "run" 
     end 



     [2014-03-02T01:00:32+00:00] INFO: Running queued delayed notifications before re-raising exception 
     [2014-03-02T01:00:32+00:00] DEBUG: Re-raising exception: NoMethodError - ruby_block[Compile Custom OpsWorks Run List] (opsworks_custom_cookbooks::execute line 3) had an error: NoMethodError: undefined method `[]' for nil:NilClass 
     /opt/aws/opsworks/releases/20140211150717_220/site-cookbooks/python/recipes/pip.rb:26:in `from_file' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/cookbook_version.rb:346:in `load_recipe' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:151:in `load_recipe' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:132:in `include_recipe' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:131:in `each' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:131:in `include_recipe' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/dsl/include_recipe.rb:26:in `include_recipe' 
     /opt/aws/opsworks/releases/20140211150717_220/site-cookbooks/newrelic/recipes/python-agent.rb:8:in `from_file' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/cookbook_version.rb:346:in `load_recipe' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:151:in `load_recipe' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:139:in `compile_recipes' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:137:in `each' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:137:in `compile_recipes' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:74:in `compile' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:86:in `load' 
     /opt/aws/opsworks/releases/20140211150717_220/cookbooks/opsworks_custom_cookbooks/recipes/execute.rb:15:in `from_file' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/provider/ruby_block.rb:33:in `call' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/provider/ruby_block.rb:33:in `action_run' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/mixin/why_run.rb:52:in `call' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/mixin/why_run.rb:52:in `add_action' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/provider.rb:151:in `converge_by' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/provider/ruby_block.rb:32:in `action_run' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/provider.rb:114:in `send' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/provider.rb:114:in `run_action' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/resource.rb:617:in `run_action' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/runner.rb:50:in `run_action' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/runner.rb:82:in `converge' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/runner.rb:82:in `each' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/runner.rb:82:in `converge' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/resource_collection.rb:94:in `execute_each_resource' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/resource_collection/stepable_iterator.rb:116:in `call' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/resource_collection/stepable_iterator.rb:116:in `call_iterator_block' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/resource_collection/stepable_iterator.rb:85:in `step' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/resource_collection/stepable_iterator.rb:104:in `iterate' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/resource_collection/stepable_iterator.rb:55:in `each_with_index' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/resource_collection.rb:92:in `execute_each_resource' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/runner.rb:81:in `converge' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/client.rb:404:in `converge' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/client.rb:469:in `do_run' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/client.rb:200:in `run' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/application.rb:190:in `run_chef_client' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/application/solo.rb:239:in `run_application' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/application/solo.rb:231:in `loop' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/application/solo.rb:231:in `run_application' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/application.rb:73:in `run' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/chef-solo:25 
     /opt/aws/opsworks/current/bin/chef-solo:16:in `load' 
     /opt/aws/opsworks/current/bin/chef-solo:16 
     [2014-03-02T01:00:32+00:00] ERROR: Running exception handlers 
     [2014-03-02T01:00:32+00:00] ERROR: Exception handlers complete 
     [2014-03-02T01:00:32+00:00] FATAL: Stacktrace dumped to /opt/aws/opsworks/releases/20140211150717_220/chef-stacktrace.out 
     [2014-03-02T01:00:32+00:00] DEBUG: NoMethodError: ruby_block[Compile Custom OpsWorks Run List] (opsworks_custom_cookbooks::execute line 3) had an error: NoMethodError: undefined method `[]' for nil:NilClass 
     /opt/aws/opsworks/releases/20140211150717_220/site-cookbooks/python/recipes/pip.rb:26:in `from_file' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/cookbook_version.rb:346:in `load_recipe' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:151:in `load_recipe' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:132:in `include_recipe' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:131:in `each' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:131:in `include_recipe' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/dsl/include_recipe.rb:26:in `include_recipe' 
     /opt/aws/opsworks/releases/20140211150717_220/site-cookbooks/newrelic/recipes/python-agent.rb:8:in `from_file' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/cookbook_version.rb:346:in `load_recipe' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:151:in `load_recipe' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:139:in `compile_recipes' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:137:in `each' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:137:in `compile_recipes' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:74:in `compile' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:86:in `load' 
     /opt/aws/opsworks/releases/20140211150717_220/cookbooks/opsworks_custom_cookbooks/recipes/execute.rb:15:in `from_file' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/provider/ruby_block.rb:33:in `call' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/provider/ruby_block.rb:33:in `action_run' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/mixin/why_run.rb:52:in `call' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/mixin/why_run.rb:52:in `add_action' 
... 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/client.rb:404:in `converge' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/client.rb:469:in `do_run' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/client.rb:200:in `run' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/application.rb:190:in `run_chef_client' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/application/solo.rb:239:in `run_application' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/application/solo.rb:231:in `loop' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/application/solo.rb:231:in `run_application' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/../lib/chef/application.rb:73:in `run' 
     /opt/aws/opsworks/releases/20140211150717_220/vendor/gems/chef-11.4.4/bin/chef-solo:25 
     /opt/aws/opsworks/current/bin/chef-solo:16:in `load' 
     /opt/aws/opsworks/current/bin/chef-solo:16 
     [2014-03-02T01:00:32+00:00] FATAL: NoMethodError: ruby_block[Compile Custom OpsWorks Run List] (opsworks_custom_cookbooks::execute line 3) had an error: NoMethodError: undefined method `[]' for nil:NilClass 

ответ

0

Ваш вопрос один вещица не ясно. Как выглядят ваши рецепты слоя? Являются ли они в правильном порядке: python, newrelic?

Вы используете python :: pip напрямую или python? Возможно, вам потребуется включить python, а не просто: pip

Смежные вопросы