jonlives / knife-flip

A knife plugin to quickly move a node between environments
76 stars 7 forks source link

Doesn't work with nodes that don't have any recipes #6

Closed bknowles closed 6 years ago

bknowles commented 10 years ago

So, testing this plugin with a node that has been newly created but has not yet completed a chef-client run, it looks like the code is looking for recipes to validate as being in the target environment and if the node does not currently have any recipes, then knife flip will bomb out:

Exception: NoMethodError: Undefined method or attribute recipes' onnode'

jonlives commented 10 years ago

@bknowles I haven't been able to replicate this issue on blank nodes. What version of ruby, chef & knife is this happening with?

bknowles commented 10 years ago

That was probably with Ruby 1.8.7 and chef-client 11.8.something. I've since upgraded to Ruby 2.0.0-something, so I should give that another try.

Thanks for the reminder!

jonlives commented 10 years ago

@bknowles thanks, let me know how it goes!

jonlives commented 10 years ago

@bknowles just chasing up old issues - did upgrading to Ruby 2.0 solve this?