Uploading cookbooks to chef server

Hi, I’m facing this issue of authentication of nodes with the chef server when I am trying to upload cookbooks to the server.

This is the error message I get all the time:
ERROR: Failed to authenticate to https://api.chef.io/organizations/[org] as node1 with key C:/chef/.chef/testClient.pem
Response: Invalid signature for user or client ‘node1’

Knife Code:
current_dir = File.dirname(FILE)
log_level :info
log_location STDOUT
node_name "node1"
validation_client_name "[org]-validator"
validation_key "#{current_dir}/[org]-validator.pem"
client_key "#{current_dir}/testClient.pem"
chef_server_url “https://api.chef.io/organizations/[org]
cookbook_path [”#{current_dir}/…/cookbooks”]
knife[:azure_publish_settings_file] = “azure.publishsettings”

It seems you’ve set your node_name to node1 and that likely isn’t the name that matches the client key you’ve created. knife client list will show you created clients and should reveal the name of the workstation client if you created one which you can then fix there.

Cheers,

Hi,

Thanks for the information. It works fine now.