[chef] Re: Node won't stay in configured environment


Chronological Thread 
  • From: Steven Danna < >
  • To:
  • Cc:
  • Subject: [chef] Re: Node won't stay in configured environment
  • Date: Thu, 20 Oct 2011 11:20:11 -0700

On Thu, Oct 20, 2011 at 11:16 AM, Benoit Caron < "> > wrote:
I have this node I want to change from my "preproduction" to "production" chef environment.

If I edit the node in the Web UI, when I submit the form it says that my node is in the correct environment. But if I recheck the node list or refresh the node list, it still says "preproduction".

If I use knife like this:

knife exec -E 'nodes.transform("name:my-node-name-in-chef") { |n| n.chef_environment("production") }'

and then do a 

knife node show my-node-name-in-chef

It still say "preproduction" too... except that odd time when it DID said production, as expected... but got back to "preproduction" on next call to knife node show.

Is it possible that you have the environment set in /etc/chef/client.rb on that node and that the node is running chef-client very frequently? 

Cheers,

Steven



Archive powered by MHonArc 2.6.16.

§