chef-boneyard / chef-provisioning

A library for creating machines and infrastructures idempotently in Chef.
Apache License 2.0
524 stars 164 forks source link

chef-client -z can't find my ssh key when creating aws machine_image #234

Closed skinney6 closed 9 years ago

skinney6 commented 9 years ago
RuntimeError: machine_image[kafka-img] (@recipe_files::/home/user/chef/cookbooks/kafka-img/recipes/default.rb line 49) had an error: RuntimeError: Server has key name 'foo.bar.pem', but the corresponding private key was not found locally.  Check if the key is in Chef::Config.private_key_paths: /home/user/.chef/keys, /home/user/.ssh

This is a good key. I use it all them time. I've put it in both directories listed but chef just doesn't find it.

johnewart commented 9 years ago

Which driver are you using, and can you provide some more information like the recipe you are using?

mikesimons commented 9 years ago

I know this is closed but just came across this and this is up in google results for the problem. Root cause for me was https://github.com/chef/cheffish/issues/62