This is a super basic task, but I can't find documentation on it. I am booting EC2 machines using a chef-server and chef. If that fails i would like to fix the recipes and then reinstall the role and recipes on that machine without taking the node out and creating it again. I cannot find the command that does that.
If I run chef-client on the machine I get:
chef-client
[Wed, 18 Jan 2012 11:23:58 +0000] INFO: *** Chef 0.10.0 ***
[Wed, 18 Jan 2012 11:23:59 +0000] INFO: Run List is []
[Wed, 18 Jan 2012 11:23:59 +0000] INFO: Run List expands to []
[Wed, 18 Jan 2012 11:23:59 +0000] INFO: Starting Chef Run for gidsy-staging-web
[Wed, 18 Jan 2012 11:23:59 +0000] INFO: Loading cookbooks []
[Wed, 18 Jan 2012 11:23:59 +0000] WARN: Node gidsy-staging-web has an empty run list.
[Wed, 18 Jan 2012 11:23:59 +0000] INFO: Chef Run complete in 0.508629 seconds
[Wed, 18 Jan 2012 11:23:59 +0000] INFO: Running report handlers
[Wed, 18 Jan 2012 11:23:59 +0000] INFO: Report handlers complete
Thanks
I have encountered the same issue and this is how I have resolved the issue.
First, I apply the role(s) in question to the instance using knife:
$ knife node run_list add [NODE] [ENTRY]
Be sure and include the items in [ENTRY] in quotes (for example, "role[my-role]").
Once the role has been applied to the EC2 instance, I then invoke chef-client on the instance in question.
$ sudo chef-client
This should speed up your development cycle substantially.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With