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

AWS provisioning stopped work - Getting 403 Forbidden: error #469

Open
vinsleo opened this issue Oct 28, 2015 · 11 comments
Open

AWS provisioning stopped work - Getting 403 Forbidden: error #469

vinsleo opened this issue Oct 28, 2015 · 11 comments
Labels
Triage: Confirmed Indicates and issue has been confirmed as described. Triage: Needs Information Indicates an issue needs more information in order to work on it. Type: Bug Doesn't work as expected.

Comments

@vinsleo
Copy link

vinsleo commented Oct 28, 2015

    - write file /etc/chef/client.pem on crowd-engagement0.1.26-SNAPSHOT[2015-10-28T00:12:59+00:00] INFO: Processing chef_client[crowd-engagement0.1.26-SNAPSHOT] action create (basic_chef_client::block line 145)
[2015-10-28T00:12:59+00:00] INFO: HTTP Request Returned 404 Object Not Found: error
[2015-10-28T00:13:00+00:00] INFO: HTTP Request Returned 403 Forbidden: error

Attached is the debug log

Tried resetting the KEY and downloaded the started kit still doesnt work.
This was working before
however the working log had slightly different line numbers. so not sure if its the CHEFDK's latest version
issue

for e.g. following line if from the logs of the run that worked correctly

[2015-09-25T14:04:07+00:00] INFO: Processing chef_node[crowd-engagementLATEST] action create (basic_chef_client::block line 143)

compared to the attached log

[2015-10-28T00:27:47+00:00] INFO: Processing chef_client[crowd-engagement0.1.26-SNAPSHOT] action create (basic_chef_client::block line 145)
@vinsleo
Copy link
Author

vinsleo commented Oct 28, 2015

LOGS:

[2015-10-28T00:27:47+00:00] DEBUG: Chef::HTTP calling Chef::HTTP::RemoteRequestID#handle_request
[2015-10-28T00:27:47+00:00] DEBUG: Initiating GET to https://api.chef.io/organizations/vinsleo/clients/crowd-engagement0.1.26-SNAPSHOT
[2015-10-28T00:27:47+00:00] DEBUG: ---- HTTP Request Header Data: ----
[2015-10-28T00:27:47+00:00] DEBUG: Accept: application/json
[2015-10-28T00:27:47+00:00] DEBUG: Accept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
[2015-10-28T00:27:47+00:00] DEBUG: X-OPS-SIGN: algorithm=sha1;version=1.0;
[2015-10-28T00:27:47+00:00] DEBUG: X-OPS-USERID: ip-172-31-37-197.eu-west-1.compute.internal
[2015-10-28T00:27:47+00:00] DEBUG: X-OPS-TIMESTAMP: 2015-10-28T00:27:47Z
[2015-10-28T00:27:47+00:00] DEBUG: X-OPS-CONTENT-HASH: 2jmj7l5rSw0yVb/vlWAYkK/YBwk=
[2015-10-28T00:27:47+00:00] DEBUG: X-OPS-AUTHORIZATION-1: bKJCk+MT9+wckCDyyMwT3pC9tIDU5cMNo7nvw42m1pldk9WrG8lzsx2eIwt0
[2015-10-28T00:27:47+00:00] DEBUG: X-OPS-AUTHORIZATION-2: 3azMtwAdhbzqi/EvDvZTgvda68w5DckhL9XiIOgaHk65EN8FIgs52nEVGnma
[2015-10-28T00:27:47+00:00] DEBUG: X-OPS-AUTHORIZATION-3: n636cxfri85uamiczrJiZaVq2kN+5n5jA1L6vDPGN+2v0Apncm5zw7X8v+SP
[2015-10-28T00:27:47+00:00] DEBUG: X-OPS-AUTHORIZATION-4: 8oQvxuI9YafEvIhkLUyqDVpjd4vCtV1cBd+DYUhuTF0H/cWk0q1YYTGRlXQG
[2015-10-28T00:27:47+00:00] DEBUG: X-OPS-AUTHORIZATION-5: CIgFx3P8vn+ssEezuqrMFW2AHV7bmKPkCY16SUG/ruuEu3W8ABP4b1j8DsPW
[2015-10-28T00:27:47+00:00] DEBUG: X-OPS-AUTHORIZATION-6: 5xIfPy47rSYAEcYLPdBQw9KOByyHyxd14Ceo0v3+rQ==
[2015-10-28T00:27:47+00:00] DEBUG: HOST: api.chef.io:443
[2015-10-28T00:27:47+00:00] DEBUG: X-Ops-Server-API-Version: 0
[2015-10-28T00:27:47+00:00] DEBUG: X-REMOTE-REQUEST-ID: 7a0773bf-ab09-46cb-a4e3-2cf6e9ee160d
[2015-10-28T00:27:47+00:00] DEBUG: ---- End HTTP Request Header Data ----
[2015-10-28T00:27:48+00:00] DEBUG: ---- HTTP Status and Header Data: ----
[2015-10-28T00:27:48+00:00] DEBUG: HTTP 1.1 404 Object Not Found
[2015-10-28T00:27:48+00:00] DEBUG: date: Wed, 28 Oct 2015 00:27:48 GMT
[2015-10-28T00:27:48+00:00] DEBUG: server: openresty/1.7.10.1
[2015-10-28T00:27:48+00:00] DEBUG: x-ops-api-info: flavor=cs;version=12.0.0;oc_erchef=12.2.0+20151005111019
[2015-10-28T00:27:48+00:00] DEBUG: x-ops-server-api-version: {"min_version":"0","max_version":"1","request_version":"0","response_version":"0"}
[2015-10-28T00:27:48+00:00] DEBUG: content-length: 64
[2015-10-28T00:27:48+00:00] DEBUG: connection: Close
[2015-10-28T00:27:48+00:00] DEBUG: ---- End HTTP Status/Header Data ----
[2015-10-28T00:27:48+00:00] DEBUG: ---- HTTP Response Body ----
[2015-10-28T00:27:48+00:00] DEBUG: {"error":["Cannot load client crowd-engagement0.1.26-SNAPSHOT"]}
[2015-10-28T00:27:48+00:00] DEBUG: ---- End HTTP Response Body -----
[2015-10-28T00:27:48+00:00] DEBUG: Chef::HTTP calling Chef::HTTP::RemoteRequestID#handle_response
[2015-10-28T00:27:48+00:00] DEBUG: Chef::HTTP calling Chef::HTTP::Authenticator#handle_response
[2015-10-28T00:27:48+00:00] DEBUG: Chef::HTTP calling Chef::HTTP::Decompressor#handle_response
[2015-10-28T00:27:48+00:00] DEBUG: Chef::HTTP calling Chef::HTTP::CookieManager#handle_response
[2015-10-28T00:27:48+00:00] DEBUG: Chef::HTTP calling Chef::HTTP::JSONOutput#handle_response
[2015-10-28T00:27:48+00:00] DEBUG: Expected JSON response, but got content-type ''
[2015-10-28T00:27:48+00:00] DEBUG: Chef::HTTP calling Chef::HTTP::JSONInput#handle_response
[2015-10-28T00:27:48+00:00] INFO: HTTP Request Returned 404 Object Not Found: error
[2015-10-28T00:27:48+00:00] DEBUG: Chef::HTTP calling Chef::HTTP::JSONInput#handle_request
[2015-10-28T00:27:48+00:00] DEBUG: Chef::HTTP calling Chef::HTTP::JSONOutput#handle_request
[2015-10-28T00:27:48+00:00] DEBUG: Chef::HTTP calling Chef::HTTP::CookieManager#handle_request
[2015-10-28T00:27:48+00:00] DEBUG: Chef::HTTP calling Chef::HTTP::Decompressor#handle_request
[2015-10-28T00:27:48+00:00] DEBUG: Chef::HTTP calling Chef::HTTP::Authenticator#handle_request
[2015-10-28T00:27:48+00:00] DEBUG: Signing the request as ip-172-31-37-197.eu-west-1.compute.internal
[2015-10-28T00:27:48+00:00] DEBUG: String to sign: 'Method:POST
Hashed Path:DzWsbVdS8yxWH/GObBHBoerTpHM=
X-Ops-Content-Hash:mSuoxcmRA4e3O/VHqDOQVh8PKtw=
X-Ops-Timestamp:2015-10-28T00:27:48Z
X-Ops-UserId:ip-172-31-37-197.eu-west-1.compute.internal'
Header hash: {"X-Ops-Sign"=>"algorithm=sha1;version=1.0;", "X-Ops-Userid"=>"ip-172-31-37-197.eu-west-1.compute.internal", "X-Ops-Timestamp"=>"2015-10-28T00:27:48Z", "X-Ops-Content-Hash"=>"mSuoxcmRA4e3O/VHqDOQVh8PKtw=", "X-Ops-Authorization-1"=>"S8mJic2NRIVW8wPtgqE8cpidA/U/GNYo1I6ZIgxd4B2ojCsmTpbeg9LLCEi/", "X-Ops-Authorization-2"=>"9zRgrwZ5a0m3yzv5JZOnRklpN3wHtX5BRTPN0nZQCknSq2rK7oWJApw+oulZ", "X-Ops-Authorization-3"=>"UBDMpRNB/s6PDe7jHKsKebL7Mv5kFfRsUR6oRdUfy1Gf3rMCjYcWv9uI8WDR", "X-Ops-Authorization-4"=>"NJPkqRlvtVNCjWGmBcyKAzdUpQN1i5tj2tQscc6tC+mZ3k6o/gOmIgbbr5ww", "X-Ops-Authorization-5"=>"Bea9L8W0RUUldmxzE/i9SYsjGzn0hK7+EkjiJQx/da3mCLmXcUx0Ut23saMV", "X-Ops-Authorization-6"=>"vHfhv8mU1FVmrBJsYcdjS6dXBqtB3NUj3wwPN7rJGw=="}
[2015-10-28T00:27:48+00:00] DEBUG: Chef::HTTP calling Chef::HTTP::RemoteRequestID#handle_request
[2015-10-28T00:27:48+00:00] DEBUG: Initiating POST to https://api.chef.io/organizations/vinsleo/clients
[2015-10-28T00:27:48+00:00] DEBUG: ---- HTTP Request Header Data: ----
[2015-10-28T00:27:48+00:00] DEBUG: Content-Type: application/json
[2015-10-28T00:27:48+00:00] DEBUG: Accept: application/json
[2015-10-28T00:27:48+00:00] DEBUG: Accept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
[2015-10-28T00:27:48+00:00] DEBUG: X-OPS-SIGN: algorithm=sha1;version=1.0;
[2015-10-28T00:27:48+00:00] DEBUG: X-OPS-USERID: ip-172-31-37-197.eu-west-1.compute.internal
[2015-10-28T00:27:48+00:00] DEBUG: X-OPS-TIMESTAMP: 2015-10-28T00:27:48Z
[2015-10-28T00:27:48+00:00] DEBUG: X-OPS-CONTENT-HASH: mSuoxcmRA4e3O/VHqDOQVh8PKtw=
[2015-10-28T00:27:48+00:00] DEBUG: X-OPS-AUTHORIZATION-1: S8mJic2NRIVW8wPtgqE8cpidA/U/GNYo1I6ZIgxd4B2ojCsmTpbeg9LLCEi/
[2015-10-28T00:27:48+00:00] DEBUG: X-OPS-AUTHORIZATION-2: 9zRgrwZ5a0m3yzv5JZOnRklpN3wHtX5BRTPN0nZQCknSq2rK7oWJApw+oulZ
[2015-10-28T00:27:48+00:00] DEBUG: X-OPS-AUTHORIZATION-3: UBDMpRNB/s6PDe7jHKsKebL7Mv5kFfRsUR6oRdUfy1Gf3rMCjYcWv9uI8WDR
[2015-10-28T00:27:48+00:00] DEBUG: X-OPS-AUTHORIZATION-4: NJPkqRlvtVNCjWGmBcyKAzdUpQN1i5tj2tQscc6tC+mZ3k6o/gOmIgbbr5ww
[2015-10-28T00:27:48+00:00] DEBUG: X-OPS-AUTHORIZATION-5: Bea9L8W0RUUldmxzE/i9SYsjGzn0hK7+EkjiJQx/da3mCLmXcUx0Ut23saMV
[2015-10-28T00:27:48+00:00] DEBUG: X-OPS-AUTHORIZATION-6: vHfhv8mU1FVmrBJsYcdjS6dXBqtB3NUj3wwPN7rJGw==
[2015-10-28T00:27:48+00:00] DEBUG: HOST: api.chef.io:443
[2015-10-28T00:27:48+00:00] DEBUG: X-Ops-Server-API-Version: 0
[2015-10-28T00:27:48+00:00] DEBUG: X-REMOTE-REQUEST-ID: 7a0773bf-ab09-46cb-a4e3-2cf6e9ee160d
[2015-10-28T00:27:48+00:00] DEBUG: Content-Length: 618
[2015-10-28T00:27:48+00:00] DEBUG: ---- End HTTP Request Header Data ----
[2015-10-28T00:27:48+00:00] DEBUG: ---- HTTP Status and Header Data: ----
[2015-10-28T00:27:48+00:00] DEBUG: HTTP 1.1 403 Forbidden
[2015-10-28T00:27:48+00:00] DEBUG: date: Wed, 28 Oct 2015 00:27:48 GMT
[2015-10-28T00:27:48+00:00] DEBUG: server: openresty/1.7.10.1
[2015-10-28T00:27:48+00:00] DEBUG: x-ops-api-info: flavor=cs;version=12.0.0;oc_erchef=12.2.0+20151005111019
[2015-10-28T00:27:48+00:00] DEBUG: x-ops-server-api-version: {"min_version":"0","max_version":"1","request_version":"0","response_version":"0"}
[2015-10-28T00:27:48+00:00] DEBUG: content-length: 39
[2015-10-28T00:27:48+00:00] DEBUG: connection: Close
[2015-10-28T00:27:48+00:00] DEBUG: ---- End HTTP Status/Header Data ----
[2015-10-28T00:27:48+00:00] DEBUG: ---- HTTP Response Body ----
[2015-10-28T00:27:48+00:00] DEBUG: {"error":["missing create permission"]}
[2015-10-28T00:27:48+00:00] DEBUG: ---- End HTTP Response Body -----
[2015-10-28T00:27:48+00:00] DEBUG: ---- HTTP Request Body ----
[2015-10-28T00:27:48+00:00] DEBUG: {"name":"crowd-engagement0.1.26-SNAPSHOT","clientname":"crowd-engagement0.1.26-SNAPSHOT","admin":false,"validator":false,"chef_type":"client","public_key":"MY PUBLIC KEY HERE \n"}
[2015-10-28T00:27:48+00:00] DEBUG: ---- End HTTP Request Body ----
[2015-10-28T00:27:48+00:00] DEBUG: Chef::HTTP calling Chef::HTTP::RemoteRequestID#handle_response
[2015-10-28T00:27:48+00:00] DEBUG: Chef::HTTP calling Chef::HTTP::Authenticator#handle_response
[2015-10-28T00:27:48+00:00] DEBUG: Chef::HTTP calling Chef::HTTP::Decompressor#handle_response
[2015-10-28T00:27:48+00:00] DEBUG: Chef::HTTP calling Chef::HTTP::CookieManager#handle_response
[2015-10-28T00:27:48+00:00] DEBUG: Chef::HTTP calling Chef::HTTP::JSONOutput#handle_response
[2015-10-28T00:27:48+00:00] DEBUG: Expected JSON response, but got content-type ''
[2015-10-28T00:27:48+00:00] DEBUG: Chef::HTTP calling Chef::HTTP::JSONInput#handle_response
[2015-10-28T00:27:48+00:00] INFO: HTTP Request Returned 403 Forbidden: error
[2015-10-28T00:27:48+00:00] INFO: Running queued delayed notifications before re-raising exception
[2015-10-28T00:27:48+00:00] DEBUG: Closing SSH session on ec2-user@52.30.229.254

    ================================================================================
    Error executing action `converge` on resource 'machine[crowd-engagement0.1.26-SNAPSHOT]'
    ================================================================================

    Net::HTTPServerException
    ------------------------
    chef_client[crowd-engagement0.1.26-SNAPSHOT] (basic_chef_client::block line 145) had an error: Net::HTTPServerException: 403 "Forbidden"

    Resource Declaration:
    ---------------------
    # In /home/ubuntu/.chef/cache/cookbooks/crowd-engagement/recipes/aws-setup.rb
17: machine'crowd-engagement'+node['nexus']['version'] do
     18:   files '/etc/chef/encrypted_data_bag_secret' => { :content => 'MY DATA BAG SECRET HERE' }
     19:    recipe 'crowd-engagement'
     20:    action :converge
     21: end

    Compiled Resource:
    ------------------
    # Declared in /home/ubuntu/.chef/cache/cookbooks/crowd-engagement/recipes/aws-setup.rb:17:in `from_file'

    machine("crowd-engagement0.1.26-SNAPSHOT") do
      action [:converge]
      retries 0
      retry_delay 2
      default_guard_interpreter :default
      chef_server {:chef_server_url=>"https://api.chef.io/organizations/vinsleo", :options=>{:client_name=>"ip-172-31-37-197.eu-west-1.compute.internal", :signing_key_filename=>"/etc/chef/client.pem", :api_version=>"0"}}
      driver "aws"
      machine_options {:ssh_username=>"ec2-user", :bootstrap_options=>{:key_name=>"capco-ilabs", :image_id=>"ami-25158352", :instance_type=>"t2.micro", :security_group_ids=>"WebServer"}}
      declared_type :machine
      cookbook_name "crowd-engagement"
      recipe_name "aws-setup"
      files {"/etc/chef/encrypted_data_bag_secret"=>{:content=>"MY DATA BAG SECRET HERE"}}
      run_list_modifiers [#<Chef::RunList::RunListItem:0x0000000cd1af90 @version=nil, @type=:recipe, @name="crowd-engagement">]
    end

[2015-10-28T00:27:48+00:00] INFO: Running queued delayed notifications before re-raising exception
[2015-10-28T00:27:48+00:00] DEBUG: Re-raising exception: Net::HTTPServerException - machine[crowd-engagement0.1.26-SNAPSHOT] (crowd-engagement::aws-setup line 17) had an error: Net::HTTPServerException: chef_client[crowd-engagement0.1.26-SNAPSHOT] (basic_chef_client::block line 145) had an error: Net::HTTPServerException: 403 "Forbidden"
/opt/chefdk/embedded/lib/ruby/2.1.0/net/http/response.rb:119:in `error!'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/http.rb:145:in `request'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/http.rb:126:in `post'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/cheffish-1.5.0/lib/cheffish/actor_provider_base.rb:30:in `block in create_actor'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/mixin/why_run.rb:52:in `call'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/mixin/why_run.rb:52:in `add_action'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/provider.rb:175:in `converge_by'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/cheffish-1.5.0/lib/cheffish/actor_provider_base.rb:29:in `create_actor'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/cheffish-1.5.0/lib/chef/provider/chef_client.rb:23:in `block in <class:ChefClient>'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/provider/lwrp_base.rb:160:in `instance_eval'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/provider/lwrp_base.rb:160:in `block in action'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/provider.rb:140:in `run_action'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/resource.rb:584:in `run_action'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/runner.rb:49:in `run_action'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/runner.rb:81:in `block (2 levels) in converge'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/runner.rb:81:in `each'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/runner.rb:81:in `block in converge'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/resource_collection/resource_list.rb:83:in `block in execute_each_resource'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/resource_collection/stepable_iterator.rb:116:in `call'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/resource_collection/stepable_iterator.rb:116:in `call_iterator_block'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/resource_collection/stepable_iterator.rb:85:in `step'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/resource_collection/stepable_iterator.rb:104:in `iterate'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/resource_collection/stepable_iterator.rb:55:in `each_with_index'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/resource_collection/resource_list.rb:81:in `execute_each_resource'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/runner.rb:80:in `converge'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/cheffish-1.5.0/lib/cheffish/basic_chef_client.rb:69:in `block in converge'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/cheffish-1.5.0/lib/cheffish/basic_chef_client.rb:133:in `call'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/cheffish-1.5.0/lib/cheffish/basic_chef_client.rb:133:in `with_chef_config'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/cheffish-1.5.0/lib/cheffish/basic_chef_client.rb:68:in `converge'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/cheffish-1.5.0/lib/cheffish/basic_chef_client.rb:109:in `converge_block'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-provisioning-1.4.1/lib/chef/provisioning.rb:12:in `inline_resource'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-provisioning-1.4.1/lib/chef/provisioning/convergence_strategy/precreate_chef_objects.rb:143:in `create_chef_objects'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-provisioning-1.4.1/lib/chef/provisioning/convergence_strategy/precreate_chef_objects.rb:27:in `setup_convergence'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-provisioning-1.4.1/lib/chef/provisioning/convergence_strategy/install_sh.rb:34:in `setup_convergence'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-provisioning-1.4.1/lib/chef/provisioning/machine/basic_machine.rb:17:in `setup_convergence'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-provisioning-1.4.1/lib/chef/provider/machine.rb:58:in `block in <class:Machine>'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/provider/lwrp_base.rb:61:in `instance_eval'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/provider/lwrp_base.rb:61:in `recipe_eval_with_update_check'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/provider/lwrp_base.rb:46:in `block in action'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/provider.rb:140:in `run_action'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/resource.rb:584:in `run_action'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/runner.rb:49:in `run_action'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/runner.rb:81:in `block (2 levels) in converge'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/runner.rb:81:in `each'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/runner.rb:81:in `block in converge'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/resource_collection/resource_list.rb:83:in `block in execute_each_resource'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/resource_collection/stepable_iterator.rb:116:in `call'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/resource_collection/stepable_iterator.rb:116:in `call_iterator_block'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/resource_collection/stepable_iterator.rb:85:in `step'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/resource_collection/stepable_iterator.rb:104:in `iterate'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/resource_collection/stepable_iterator.rb:55:in `each_with_index'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/resource_collection/resource_list.rb:81:in `execute_each_resource'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/runner.rb:80:in `converge'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/client.rb:654:in `block in converge'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/client.rb:649:in `catch'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/client.rb:649:in `converge'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/client.rb:688:in `converge_and_save'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/client.rb:269:in `run'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/application.rb:270:in `block in fork_chef_client'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/application.rb:258:in `fork'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/application.rb:258:in `fork_chef_client'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/application.rb:224:in `block in run_chef_client'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/local_mode.rb:39:in `with_server_connectivity'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/application.rb:212:in `run_chef_client'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/application/client.rb:402:in `block in interval_run_chef_client'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/application/client.rb:392:in `loop'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/application/client.rb:392:in `interval_run_chef_client'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/application/client.rb:382:in `run_application'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/lib/chef/application.rb:60:in `run'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.4.4/bin/chef-client:26:in `<top (required)>'
  /usr/bin/chef-client:54:in `load'
  /usr/bin/chef-client:54:in `<main>'

@evidetta-adbrain
Copy link

Hello,

I am having a similar problem with chef-provisioning AWS. To me, it seems as if it is no longer installing chef-client and bootstraping the node before attempting to converge. I am ondering if there may have been a change either in chef-provisioning or chef-provisioning-aws which may have cause the change.

@tyler-ball
Copy link
Contributor

Hey @vinsleo and @evidetta-adbrain - will you try this with the latest pre-release of the ChefDK and see if you still have the issue?

@vinsleo
Copy link
Author

vinsleo commented Nov 3, 2015

It mentions to try other version. As the latest one does not exists for ubuntu?
can you let me which one specifically to try ?

COMMAND:
curl https://omnitruck.chef.io/install.sh | sudo bash -s -- -c current -P chefdk

OUTPUT:

  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 17892  100 17892    0     0  18713      0 --:--:-- --:--:-- --:--:-- 18715
Downloading chefdk  for ubuntu...
downloading https://omnitruck.chef.io/current/chefdk/metadata?v=&p=ubuntu&pv=15.04&m=x86_64
  to file /tmp/install.sh.19067/metadata.txt
trying wget...
url https://opscode-omnibus-packages-current.s3.amazonaws.com/ubuntu/14.04/x86_64/chefdk_0.9.0%2B20151103085009-1_amd64.deb
md5 1a78479230c3cc11dcbefcf77c786a70
sha256  8eecb956168b096428f18b13799a78b0d4bf3c6bf732b384f6da899533cbcb15
version 0.9.0+20151103085009downloaded metadata file looks valid...
downloading https://opscode-omnibus-packages-current.s3.amazonaws.com/ubuntu/14.04/x86_64/chefdk_0.9.0%2B20151103085009-1_amd64.deb
  to file /tmp/install.sh.19067/chefdk_0.9.0%2B20151103085009-1_amd64.deb
trying wget...
ERROR 404
Omnitruck artifact does not exist for version  on platform ubuntu

Either this means:
   - We do not support ubuntu
   - We do not have an artifact for

This is often the latter case due to running a prerelease or RC version of chef
or a gem version which was only pushed to rubygems and not omnitruck.

You may be able to set your knife[:bootstrap_version] to the most recent stable
release of Chef to fix this problem (or the most recent stable major version number).

In order to test the version parameter, adventurous users may take the Metadata URL
below and modify the '&v=<number>' parameter until you successfully get a URL that
does not 404 (e.g. via curl or wget).  You should be able to use '&v=11' or '&v=12'
succesfully.

If you cannot fix this problem by setting the bootstrap_version, it probably means
that ubuntu is not supported.

Metadata URL: https://omnitruck.chef.io/current/chefdk/metadata?v=&p=ubuntu&pv=15.04&m=x86_64
Download URL: https://opscode-omnibus-packages-current.s3.amazonaws.com/ubuntu/14.04/x86_64/chefdk_0.9.0%2B20151103085009-1_amd64.deb

@vinsleo
Copy link
Author

vinsleo commented Nov 3, 2015

OK meanwhile tried with the following version
Download URL: https://opscode-omnibus-packages-current.s3.amazonaws.com/ubuntu/14.04/x86_64/chefdk_0.9.0%2B20151103085009-1_amd64.deb

Still get the Forbidden error

================================================================================
    Error executing action `converge` on resource 'machine[starter]'
    ================================================================================

    Net::HTTPServerException
    ------------------------
    chef_client[starter] (basic_chef_client::block line 145) had an error: Net::HTTPServerException: 403 "Forbidden"

    Resource Declaration:
    ---------------------
    # In /var/chef/cache/cookbooks/starter/recipes/aws-setup.rb

     16: machine 'starter' do
     17:   recipe 'starter'
     18: end
     19:

    Compiled Resource:
    ------------------
    # Declared in /var/chef/cache/cookbooks/starter/recipes/aws-setup.rb:16:in `from_file'

    machine("starter") do
      action [:converge]
      retries 0
      retry_delay 2
      default_guard_interpreter :default
      chef_server {:chef_server_url=>"https://api.chef.io/organizations/tomandjerry", :options=>{:client_name=>"ip-172-31-35-207.eu-west-1.compute.internal", :signing_key_filename=>"/etc/chef/client.pem", :api_version=>"0"}}
      driver "aws"
      machine_options {:ssh_username=>"ec2-user", :bootstrap_options=>{:key_name=>"capco-ilabs", :image_id=>"ami-25158352", :instance_type=>"t2.micro", :security_group_ids=>"WebServer"}}
      declared_type :machine
      cookbook_name "starter"
      recipe_name "aws-setup"
      run_list_modifiers [#<Chef::RunList::RunListItem:0x0000000ba8de40 @version=nil, @type=:recipe, @name="starter">]
    end

[2015-11-03T22:15:00+00:00] INFO: Running queued delayed notifications before re-raising exception
[2015-11-03T22:15:00+00:00] DEBUG: Re-raising exception: Net::HTTPServerException - machine[starter] (starter::aws-setup line 16) had an error: Net::HTTPServerException: chef_client[starter] (basic_chef_client::block line 145) had an error: Net::HTTPServerException: 403 "Forbidden"
/opt/chefdk/embedded/lib/ruby/2.1.0/net/http/response.rb:119:in `error!'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/http.rb:145:in `request'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/http.rb:126:in `post'
......


[2015-11-03T22:15:01+00:00] ERROR: machine[starter] (starter::aws-setup line 16) had an error: Net::HTTPServerException: chef_client[starter] (basic_chef_client::block line 145) had an error: Net::HTTPServerException: 403 "Forbidden"
[2015-11-03T22:15:01+00:00] FATAL: Chef::Exceptions::ChildConvergeError: Chef run process exited unsuccessfully (exit code 1)

@mickfeech
Copy link

I've been receiving very similar messages trying to provision to docker.

[2015-11-04T09:32:12-05:00] DEBUG: Chef::HTTP calling Chef::HTTP::Authenticator#handle_request
[2015-11-04T09:32:12-05:00] DEBUG: Signing the request as server1
[2015-11-04T09:32:12-05:00] DEBUG: String to sign: 'Method:GET
Hashed Path:3mWqCJcr2509dd2k11DLwRpSHl4=
X-Ops-Content-Hash:2jmj7l5rSw0yVb/vlWAYkK/YBwk=
X-Ops-Timestamp:2015-11-04T14:32:12Z
X-Ops-UserId:server1'
Header hash: {"X-Ops-Sign"=>"algorithm=sha1;version=1.0;", "X-Ops-Userid"=>"server1", "X-Ops-Timestamp"=>"2015-11-04T14:32:12Z", "X-Ops-Content-Hash"=>"2jmj7l5rSw0yVb/vlWAYkK/YBwk=", "X-Ops-Authorization-1"=>"SdmjkCyepkKHyMFIQTR1c4HV6PkNiYd1/23qpn7pm2hrHjkCXca3GMSMdxTM", "X-Ops-Authorization-2"=>"IHL9OipB3fHNA2T4zrY+ohAriBrwEf5bcyYnzSz84Y3ktGATA0aoTM2mfkg/", "X-Ops-Authorization-3"=>"qNQ1jfFI6O1ljBv3K3mE5pDuyST4fzgJDQg4aeuHqV5aepY+Bp+8M8u3ZvFD", "X-Ops-Authorization-4"=>"RWeQ4HU1rMt1dzRg1HrsNQPTraIpFG2EDdDhS0uIWvS4lXQCoJ38GQqYdSlC", "X-Ops-Authorization-5"=>"wRVS1RSpM2i7iD5eTvq3+zxS1n24xfJcq5jXZbNMCR5fjT0qZCsXK7+f0Nq5", "X-Ops-Authorization-6"=>"Ag78sfQAyCE0JZiK5WokfWa/W60o1rOU9eKXMdenpA=="}
[2015-11-04T09:32:12-05:00] DEBUG: Chef::HTTP calling Chef::HTTP::RemoteRequestID#handle_request
[2015-11-04T09:32:12-05:00] DEBUG: Initiating GET to https://server1/organizations/my_org/clients/app.myapp.local
[2015-11-04T09:32:12-05:00] DEBUG: ---- HTTP Request Header Data: ----
[2015-11-04T09:32:12-05:00] DEBUG: Accept: application/json
[2015-11-04T09:32:12-05:00] DEBUG: Accept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-SIGN: algorithm=sha1;version=1.0;
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-USERID: server1
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-TIMESTAMP: 2015-11-04T14:32:12Z
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-CONTENT-HASH: 2jmj7l5rSw0yVb/vlWAYkK/YBwk=
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-AUTHORIZATION-1: SdmjkCyepkKHyMFIQTR1c4HV6PkNiYd1/23qpn7pm2hrHjkCXca3GMSMdxTM
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-AUTHORIZATION-2: IHL9OipB3fHNA2T4zrY+ohAriBrwEf5bcyYnzSz84Y3ktGATA0aoTM2mfkg/
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-AUTHORIZATION-3: qNQ1jfFI6O1ljBv3K3mE5pDuyST4fzgJDQg4aeuHqV5aepY+Bp+8M8u3ZvFD
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-AUTHORIZATION-4: RWeQ4HU1rMt1dzRg1HrsNQPTraIpFG2EDdDhS0uIWvS4lXQCoJ38GQqYdSlC
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-AUTHORIZATION-5: wRVS1RSpM2i7iD5eTvq3+zxS1n24xfJcq5jXZbNMCR5fjT0qZCsXK7+f0Nq5
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-AUTHORIZATION-6: Ag78sfQAyCE0JZiK5WokfWa/W60o1rOU9eKXMdenpA==
[2015-11-04T09:32:12-05:00] DEBUG: HOST: server1:443
[2015-11-04T09:32:12-05:00] DEBUG: X-Ops-Server-API-Version: 0
[2015-11-04T09:32:12-05:00] DEBUG: X-REMOTE-REQUEST-ID: dd6e97f5-36b2-4aa5-a4c4-e40249375a90
[2015-11-04T09:32:12-05:00] DEBUG: ---- End HTTP Request Header Data ----
[2015-11-04T09:32:12-05:00] DEBUG: ---- HTTP Status and Header Data: ----
[2015-11-04T09:32:12-05:00] DEBUG: HTTP 1.1 404 Object Not Found
[2015-11-04T09:32:12-05:00] DEBUG: server: openresty/1.7.10.1
[2015-11-04T09:32:12-05:00] DEBUG: date: Wed, 04 Nov 2015 14:32:12 GMT
[2015-11-04T09:32:12-05:00] DEBUG: content-length: 48
[2015-11-04T09:32:12-05:00] DEBUG: connection: close
[2015-11-04T09:32:12-05:00] DEBUG: x-ops-server-api-version: {"min_version":"0","max_version":"1","request_version":"0","response_version":"0"}
[2015-11-04T09:32:12-05:00] DEBUG: x-ops-api-info: flavor=cs;version=12.0.0;oc_erchef=12.2.0
[2015-11-04T09:32:12-05:00] DEBUG: ---- End HTTP Status/Header Data ----
[2015-11-04T09:32:12-05:00] DEBUG: ---- HTTP Response Body ----
[2015-11-04T09:32:12-05:00] DEBUG: {"error":["Cannot load client app.myapp.local"]}
[2015-11-04T09:32:12-05:00] DEBUG: ---- End HTTP Response Body -----
[2015-11-04T09:32:12-05:00] DEBUG: Chef::HTTP calling Chef::HTTP::Authenticator#handle_request
[2015-11-04T09:32:12-05:00] DEBUG: Signing the request as server1
[2015-11-04T09:32:12-05:00] DEBUG: String to sign: 'Method:POST
Hashed Path:7rYlcOytWR8a1ZiIxpZPRmUy8xA=
X-Ops-Content-Hash:J5TyHmssKcpwEL8FQA32QZI0LeY=
X-Ops-Timestamp:2015-11-04T14:32:12Z
X-Ops-UserId:server1'
Header hash: {"X-Ops-Sign"=>"algorithm=sha1;version=1.0;", "X-Ops-Userid"=>"server1", "X-Ops-Timestamp"=>"2015-11-04T14:32:12Z", "X-Ops-Content-Hash"=>"J5TyHmssKcpwEL8FQA32QZI0LeY=", "X-Ops-Authorization-1"=>"jUEvxi1CSm52Hp1mr7QD3GNRNw+O7Z+2j9np1yi8fC2tqSVnf2sX8ZEJN/bp", "X-Ops-Authorization-2"=>"nHhcJreQrCTTo6Jmno8ru/6JkYjcw5LOjVOFHw1ppllULc/hNb+OrTmBTAhF", "X-Ops-Authorization-3"=>"EDljqAbXPdKM8kEH3JxFxop0vrfnB3vvR1j9UgnusTCjVEH8Wcd0rUsxLQQX", "X-Ops-Authorization-4"=>"ATczcl2AX5S8S5DrqQLZGQZE+DpJEUpmGRy1hQpPcVttc9JJzW0bZAHbSnr1", "X-Ops-Authorization-5"=>"fE6mMxpbK2UjMPBTI27bN8MvHvPfT7QZNdpF+jwOEM+IDWcAM0fbnZFOcIqp", "X-Ops-Authorization-6"=>"R69MJdoYMiLyLEQEAPk43p09znhRYOmQZTGgAHerHg=="}
[2015-11-04T09:32:12-05:00] DEBUG: Chef::HTTP calling Chef::HTTP::RemoteRequestID#handle_request
[2015-11-04T09:32:12-05:00] DEBUG: Initiating POST to https://server1/organizations/my_org/clients
[2015-11-04T09:32:12-05:00] DEBUG: ---- HTTP Request Header Data: ----
[2015-11-04T09:32:12-05:00] DEBUG: Content-Type: application/json
[2015-11-04T09:32:12-05:00] DEBUG: Accept: application/json
[2015-11-04T09:32:12-05:00] DEBUG: Accept-Encoding: gzip;q=1.0,deflate;q=0.6,identity;q=0.3
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-SIGN: algorithm=sha1;version=1.0;
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-USERID: server1
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-TIMESTAMP: 2015-11-04T14:32:12Z
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-CONTENT-HASH: J5TyHmssKcpwEL8FQA32QZI0LeY=
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-AUTHORIZATION-1: jUEvxi1CSm52Hp1mr7QD3GNRNw+O7Z+2j9np1yi8fC2tqSVnf2sX8ZEJN/bp
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-AUTHORIZATION-2: nHhcJreQrCTTo6Jmno8ru/6JkYjcw5LOjVOFHw1ppllULc/hNb+OrTmBTAhF
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-AUTHORIZATION-3: EDljqAbXPdKM8kEH3JxFxop0vrfnB3vvR1j9UgnusTCjVEH8Wcd0rUsxLQQX
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-AUTHORIZATION-4: ATczcl2AX5S8S5DrqQLZGQZE+DpJEUpmGRy1hQpPcVttc9JJzW0bZAHbSnr1
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-AUTHORIZATION-5: fE6mMxpbK2UjMPBTI27bN8MvHvPfT7QZNdpF+jwOEM+IDWcAM0fbnZFOcIqp
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-AUTHORIZATION-6: R69MJdoYMiLyLEQEAPk43p09znhRYOmQZTGgAHerHg==
[2015-11-04T09:32:12-05:00] DEBUG: HOST: server1:443
[2015-11-04T09:32:12-05:00] DEBUG: X-Ops-Server-API-Version: 0
[2015-11-04T09:32:12-05:00] DEBUG: X-REMOTE-REQUEST-ID: dd6e97f5-36b2-4aa5-a4c4-e40249375a90
[2015-11-04T09:32:12-05:00] DEBUG: Content-Length: 586
[2015-11-04T09:32:12-05:00] DEBUG: ---- End HTTP Request Header Data ----
[2015-11-04T09:32:12-05:00] DEBUG: ---- HTTP Status and Header Data: ----
[2015-11-04T09:32:12-05:00] DEBUG: HTTP 1.1 403 Forbidden
[2015-11-04T09:32:12-05:00] DEBUG: server: openresty/1.7.10.1
[2015-11-04T09:32:12-05:00] DEBUG: date: Wed, 04 Nov 2015 14:32:12 GMT
[2015-11-04T09:32:12-05:00] DEBUG: content-length: 39
[2015-11-04T09:32:12-05:00] DEBUG: connection: close
[2015-11-04T09:32:12-05:00] DEBUG: x-ops-server-api-version: {"min_version":"0","max_version":"1","request_version":"0","response_version":"0"}
[2015-11-04T09:32:12-05:00] DEBUG: x-ops-api-info: flavor=cs;version=12.0.0;oc_erchef=12.2.0
[2015-11-04T09:32:12-05:00] DEBUG: ---- End HTTP Status/Header Data ----
[2015-11-04T09:32:12-05:00] DEBUG: ---- HTTP Response Body ----
[2015-11-04T09:32:12-05:00] DEBUG: {"error":["missing create permission"]}
[2015-11-04T09:32:12-05:00] DEBUG: ---- End HTTP Response Body -----
[2015-11-04T09:32:12-05:00] DEBUG: ---- HTTP Request Body ----
[2015-11-04T09:32:12-05:00] DEBUG: {"name":"app.myapp.local","clientname":"app.myapp.local","admin":false,"validator":false,"chef_type":"client","public_key":"-----BEGIN PUBLIC KEY-----\nMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAyMY98wd6iTOBiCxOYfNe\nO/Q+Q8t2e0Iv/GLiBunvRxirsIP2gsTUNbtYaOvUJP6A4nWpv2b7XJXczxVBw9nl\neQKB6qb4t9FIxZaElH7wzp5+74RQkl7jPvkh9qcWZBWcNCa5kRaPEif9unKqG6NM\nS4OhDFdxt6tXqMlVXhk8/PLFXY7/G7Y5JE+k9DqxgpiQFbBeeCjTcQJr6MHvt/Cl\nNh8T3hy2BqQCJyssBSvSIsJfhfc9XNEkcohq3LhBbGyojGWXA9LlUjphGIv010QY\nXP6gCpXD/sTCegbnGdeplUyi62gZZSLcgSNPr5UqTXZVGY0oW+0Fa1JnnV9BEbGx\n/wIDAQAB\n-----END PUBLIC KEY-----\n"}
[2015-11-04T09:32:12-05:00] DEBUG: ---- End HTTP Request Body ----
[2015-11-04T09:32:12-05:00] DEBUG: Chef::HTTP calling Chef::HTTP::RemoteRequestID#handle_response
[2015-11-04T09:32:12-05:00] DEBUG: Chef::HTTP calling Chef::HTTP::Authenticator#handle_response
[2015-11-04T09:32:12-05:00] DEBUG: Chef::HTTP calling Chef::HTTP::Decompressor#handle_response
[2015-11-04T09:32:12-05:00] DEBUG: Chef::HTTP calling Chef::HTTP::CookieManager#handle_response
[2015-11-04T09:32:12-05:00] DEBUG: Chef::HTTP calling Chef::HTTP::JSONOutput#handle_response
[2015-11-04T09:32:12-05:00] DEBUG: Expected JSON response, but got content-type ''
[2015-11-04T09:32:12-05:00] DEBUG: Chef::HTTP calling Chef::HTTP::JSONInput#handle_response
[2015-11-04T09:32:12-05:00] INFO: HTTP Request Returned 403 Forbidden: error
[2015-11-04T09:32:12-05:00] INFO: Running queued delayed notifications before re-raising exception
[2015-11-04T09:32:12-05:00] INFO: Running queued delayed notifications before re-raising exception
[2015-11-04T09:32:12-05:00] DEBUG: Re-raising exception: Net::HTTPServerException - machine[app.myapp.local] (tomcat_cluster::default line 12) had an error: Net::HTTPServerException: chef_client[app.myapp.local] (basic_chef_client::block line 145) had an error: Net::HTTPServerException: 403 "Forbidden"
/opt/chefdk/embedded/lib/ruby/2.1.0/net/http/response.rb:119:in `error!'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/http.rb:145:in `request'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/http.rb:126:in `post'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/cheffish-1.5.0/lib/cheffish/actor_provider_base.rb:30:in `block in create_actor'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/mixin/why_run.rb:52:in `call'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/mixin/why_run.rb:52:in `add_action'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/provider.rb:175:in `converge_by'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/cheffish-1.5.0/lib/cheffish/actor_provider_base.rb:29:in `create_actor'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/cheffish-1.5.0/lib/chef/provider/chef_client.rb:23:in `block in <class:ChefClient>'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/provider/lwrp_base.rb:86:in `instance_eval'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/provider/lwrp_base.rb:86:in `block in action'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/provider.rb:144:in `run_action'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/resource.rb:585:in `run_action'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/runner.rb:49:in `run_action'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/runner.rb:81:in `block (2 levels) in converge'
 /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/runner.rb:81:in `each'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/runner.rb:81:in `block in converge'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/resource_collection/resource_list.rb:83:in `block in execute_each_resource'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/resource_collection/stepable_iterator.rb:116:in `call'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/resource_collection/stepable_iterator.rb:116:in `call_iterator_block'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/resource_collection/stepable_iterator.rb:85:in `step'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/resource_collection/stepable_iterator.rb:104:in `iterate'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/resource_collection/stepable_iterator.rb:55:in `each_with_index'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/resource_collection/resource_list.rb:81:in `execute_each_resource'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/runner.rb:80:in `converge'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/cheffish-1.5.0/lib/cheffish/basic_chef_client.rb:69:in `block in converge'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/cheffish-1.5.0/lib/cheffish/basic_chef_client.rb:133:in `call'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/cheffish-1.5.0/lib/cheffish/basic_chef_client.rb:133:in `with_chef_config'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/cheffish-1.5.0/lib/cheffish/basic_chef_client.rb:68:in `converge'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/cheffish-1.5.0/lib/cheffish/basic_chef_client.rb:109:in `converge_block'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-provisioning-1.4.1/lib/chef/provisioning.rb:12:in `inline_resource'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-provisioning-1.4.1/lib/chef/provisioning/convergence_strategy/precreate_chef_objects.rb:143:in `create_chef_objects'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-provisioning-1.4.1/lib/chef/provisioning/convergence_strategy/precreate_chef_objects.rb:27:in `setup_convergence'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-provisioning-1.4.1/lib/chef/provisioning/convergence_strategy/install_cached.rb:47:in `setup_convergence'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-provisioning-1.4.1/lib/chef/provisioning/machine/basic_machine.rb:17:in `setup_convergence'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-provisioning-1.4.1/lib/chef/provider/machine.rb:58:in `block in <class:Machine>'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/provider.rb:362:in `action_converge'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/provider.rb:144:in `run_action'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/resource.rb:585:in `run_action'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/runner.rb:49:in `run_action'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/runner.rb:81:in `block (2 levels) in converge'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/runner.rb:81:in `each'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/runner.rb:81:in `block in converge'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/resource_collection/resource_list.rb:83:in `block in execute_each_resource'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/resource_collection/stepable_iterator.rb:116:in `call'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/resource_collection/stepable_iterator.rb:116:in `call_iterator_block'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/resource_collection/stepable_iterator.rb:85:in `step'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/resource_collection/stepable_iterator.rb:104:in `iterate'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/resource_collection/stepable_iterator.rb:55:in `each_with_index'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/resource_collection/resource_list.rb:81:in `execute_each_resource'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/runner.rb:80:in `converge'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/client.rb:653:in `block in converge'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/client.rb:648:in `catch'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/client.rb:648:in `converge'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/client.rb:687:in `converge_and_save'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/client.rb:269:in `run'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/application.rb:270:in `block in fork_chef_client'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/application.rb:258:in `fork'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/application.rb:258:in `fork_chef_client'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/application.rb:224:in `block in run_chef_client'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/local_mode.rb:44:in `with_server_connectivity'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/application.rb:212:in `run_chef_client'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/application/client.rb:408:in `block in interval_run_chef_client'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/application/client.rb:398:in `loop'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/application/client.rb:398:in `interval_run_chef_client'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/application/client.rb:388:in `run_application'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/application.rb:60:in `run'
  /opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/bin/chef-client:26:in `<top (required)>'
  /bin/chef-client:54:in `load'
  /bin/chef-client:54:in `<main>'
[2015-11-04T09:32:12-05:00] ERROR: Running exception handlers
[2015-11-04T09:32:12-05:00] ERROR: Exception handlers complete
[2015-11-04T09:32:12-05:00] INFO: Sending resource update report (run-id: dd6e97f5-36b2-4aa5-a4c4-e40249375a90)
Header hash: {"X-Ops-Sign"=>"algorithm=sha1;version=1.0;", "X-Ops-Userid"=>"server1", "X-Ops-Timestamp"=>"2015-11-04T14:32:12Z", "X-Ops-Content-Hash"=>"5XSRGmqY8rm0jKWTWesRTgdwBFw=", "X-Ops-Authorization-1"=>"o0+77820zTvsFwvlGLycQdB+WBgOqAn9SaIYl2m2AptPic/HuGmSnqECtz4B", "X-Ops-Authorization-2"=>"VzhqBz13e7QbjgJw9KBGOi66zymqtE+3577xnVyyTpkWW/tbe19DS7SP43Rx", "X-Ops-Authorization-3"=>"PScjspFz/zlJUa4wE47y4Nmnety2H+psYnNn8PqwblF6HEDCF4OUPZ+uQCgK", "X-Ops-Authorization-4"=>"5hC7G6/uue/3yFno6fHg4/KoYKZsMvXYGhPG6of9JOziNeWIKVqqxhleQF57", "X-Ops-Authorization-5"=>"6s0NpcPrX3CEXR9j4GLbqQygqE1P+N4I0UIViRHVRmgwxD07hP57bcjT71RK", "X-Ops-Authorization-6"=>"fsTBC3zaoPzHPPgMeE5lx2+Mb60bOJam2xqyfa1rCA=="}
[2015-11-04T09:32:12-05:00] DEBUG: Initiating POST to https://server1/organizations/my_org/reports/nodes/server1/runs/dd6e97f5-36b2-4aa5-a4c4-e40249375a90
[2015-11-04T09:32:12-05:00] DEBUG: ---- HTTP Request Header Data: ----
[2015-11-04T09:32:12-05:00] DEBUG: X-Ops-Reporting-Protocol-Version: 0.1.0
[2015-11-04T09:32:12-05:00] DEBUG: Content-Encoding: gzip
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-SIGN: algorithm=sha1;version=1.0;
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-USERID: server1
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-TIMESTAMP: 2015-11-04T14:32:12Z
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-CONTENT-HASH: 5XSRGmqY8rm0jKWTWesRTgdwBFw=
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-AUTHORIZATION-1: o0+77820zTvsFwvlGLycQdB+WBgOqAn9SaIYl2m2AptPic/HuGmSnqECtz4B
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-AUTHORIZATION-2: VzhqBz13e7QbjgJw9KBGOi66zymqtE+3577xnVyyTpkWW/tbe19DS7SP43Rx
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-AUTHORIZATION-3: PScjspFz/zlJUa4wE47y4Nmnety2H+psYnNn8PqwblF6HEDCF4OUPZ+uQCgK
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-AUTHORIZATION-4: 5hC7G6/uue/3yFno6fHg4/KoYKZsMvXYGhPG6of9JOziNeWIKVqqxhleQF57
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-AUTHORIZATION-5: 6s0NpcPrX3CEXR9j4GLbqQygqE1P+N4I0UIViRHVRmgwxD07hP57bcjT71RK
[2015-11-04T09:32:12-05:00] DEBUG: X-OPS-AUTHORIZATION-6: fsTBC3zaoPzHPPgMeE5lx2+Mb60bOJam2xqyfa1rCA==
[2015-11-04T09:32:12-05:00] DEBUG: HOST: server1:443
[2015-11-04T09:32:12-05:00] DEBUG: X-Ops-Server-API-Version: 1
[2015-11-04T09:32:12-05:00] DEBUG: X-REMOTE-REQUEST-ID: dd6e97f5-36b2-4aa5-a4c4-e40249375a90
[2015-11-04T09:32:12-05:00] DEBUG: Content-Length: 2120
[2015-11-04T09:32:12-05:00] DEBUG: ---- End HTTP Request Header Data ----
[2015-11-04T09:32:12-05:00] DEBUG: ---- HTTP Status and Header Data: ----
[2015-11-04T09:32:12-05:00] DEBUG: HTTP 1.1 200 OK
[2015-11-04T09:32:12-05:00] DEBUG: server: openresty/1.7.10.1
[2015-11-04T09:32:12-05:00] DEBUG: date: Wed, 04 Nov 2015 14:32:12 GMT
[2015-11-04T09:32:12-05:00] DEBUG: content-type: application/json
[2015-11-04T09:32:12-05:00] DEBUG: content-length: 2
[2015-11-04T09:32:12-05:00] DEBUG: connection: close
[2015-11-04T09:32:12-05:00] DEBUG: ---- End HTTP Status/Header Data ----
[2015-11-04T09:32:12-05:00] DEBUG: Audit Reports are disabled. Skipping sending reports.
[2015-11-04T09:32:12-05:00] FATAL: Stacktrace dumped to /var/chef/cache/chef-stacktrace.out
[2015-11-04T09:32:12-05:00] DEBUG: Net::HTTPServerException: machine[app.myapp.local] (tomcat_cluster::default line 12) had an error: Net::HTTPServerException: chef_client[app.myapp.local] (basic_chef_client::block line 145) had an error: Net::HTTPServerException: 403 "Forbidden"
/opt/chefdk/embedded/lib/ruby/2.1.0/net/http/response.rb:119:in `error!'
/opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/http.rb:145:in `request'
/opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/http.rb:126:in `post'
/opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/cheffish-1.5.0/lib/cheffish/actor_provider_base.rb:30:in `block in create_actor'
/opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/mixin/why_run.rb:52:in `call'
/opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/mixin/why_run.rb:52:in `add_action'
/opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/provider.rb:175:in `converge_by'
/opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/cheffish-1.5.0/lib/cheffish/actor_provider_base.rb:29:in `create_actor'
/opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/cheffish-1.5.0/lib/chef/provider/chef_client.rb:23:in `block in <class:ChefClient>'
/opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/provider/lwrp_base.rb:86:in `instance_eval'
/opt/chefdk/embedded/lib/ruby/gems/2.1.0/gems/chef-12.5.1/lib/chef/provider/lwrp_base.rb:86:in `block in action'
[2015-11-04T09:32:12-05:00] ERROR: machine[app.myapp.local] (tomcat_cluster::default line 12) had an error: Net::HTTPServerException: chef_client[app.myapp.local] (basic_chef_client::block line 145) had an error: Net::HTTPServerException: 403 "Forbidden"
[2015-11-04T09:32:12-05:00] FATAL: Chef::Exceptions::ChildConvergeError: Chef run process exited unsuccessfully (exit code 1)

@vinsleo
Copy link
Author

vinsleo commented Nov 4, 2015

@mickfeech Thanks for sharing the link from @marc- written by @jtimberman

http://jtimberman.housepub.org/blog/2015/02/09/quick-tip-create-a-provisioner-node/

This has fixed my issue. However it has confused me.
so the link explains to create a new group, client and node. assign group to client and node. and the group has all the permissions.

I checked the permission tabs on hosted chef server console before applying this changes. It had an entry with the name of my CLIENT with all permissions on it. So I admit I was bit skeptical that this changes would work. But surprisingly they worked.

Now I just need to understand whats going on!

  • When the client/node is automatically created by just running chef-client on a box even though node has all the permissions boxes ticked it cannot successfully register the new boxes created using "machine" resource as a chef node/client
  • However if i delete that client/node, create a group with required permissions and create a new chef client/node, apply the group to it and run the chef-client it works perfectly well.

whats the magic ?

@mickfeech
Copy link

Yeah. The same thing happened to me. It looks like there are some hidden permissions in the webui. One would think (like us) that any node should be able to have the permissions to provision a container or at least documented in an official capacity.

On Wed, Nov 4, 2015 at 6:35 PM, Vinay notifications@github.com wrote:

@mickfeech Thanks for sharing the link from @marc- written by @jtimberman

http://jtimberman.housepub.org/blog/2015/02/09/quick-tip-create-a-provisioner-node/
This has fixed my issue. However it has confused me.
so the link explains to create a new group, client and node. assign group to client and node. and the group has all the permissions.
I checked the permission tabs on hosted chef server console before applying this changes. It had an entry with the name of my CLIENT with all permissions on it. So I admit I was bit skeptical that this changes would work. But surprisingly they worked.
Now I just need to understand whats going on!

  • When the client/node is automatically created by just running chef-client on a box even though node has all the permissions boxes ticked it cannot successfully register the new boxes created using "machine" resource a chef node/client
  • However if i delete that client/node, create a group with required permissions and create a new chef client/node, apply the group to it and run the chef-client it works perfectly well.

whats the magic ?

Reply to this email directly or view it on GitHub:
#469 (comment)

@evidetta-adbrain
Copy link

I managed to solve this issue tonight after a bit of Googling. As it turns out, it is not a bug in chef-provisioning but rather the ACLs on Chef Server which are causing issues. In order to provision, the provisioner needs to have the permission to create, read, update and grant permissions to new clients. What this involves in Chef Server is creating a group for your provisioner clients and granting permissions on that group to create other clients. It was a bit counter-intuitive to do since in Chef server does not provide the UI to easily assign permissions to create clients.

First, I created a provisioners group. Then I ran knife edit /acls/containers/clients.json and added the provisioners group to the appropriate permissions. Finally I ran knife edit /groups/provisioners.json and added my provisioner client to the group. After that, this solved the permissions problem.

@elthariel
Copy link
Contributor

That would be awesome if we could document this on the main documentation, to avoid spending hours on this issue :D

@GolubevV
Copy link

Hit the same issue today - the problem with ACLs for provisioning node to be able to create required object on Chef server.
The following two blog articles are describing the remediation, but it is not full (for AWS):

However, they are not full and require granting permissions to databag (at least, for AWS):

# chef server, never running provisioning before
for permission in read create update grant delete
do
  knife acl add group provisioners containers data $permission 
done

# for chef server, which has already did provisioning - also run:
for permission in read create update grant delete
do
  knife acl bulk add group provisioners data 'aws_.*' $permission
done

@tas50 tas50 added Type: Bug Doesn't work as expected. Status: Pending Contributor Response and removed Bug labels Jul 31, 2018
@tas50 tas50 added Triage: Confirmed Indicates and issue has been confirmed as described. Triage: Needs Information Indicates an issue needs more information in order to work on it. and removed Status: Confirmed labels Dec 22, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Triage: Confirmed Indicates and issue has been confirmed as described. Triage: Needs Information Indicates an issue needs more information in order to work on it. Type: Bug Doesn't work as expected.
Development

No branches or pull requests

7 participants