[chef-dev] Re: Re: clients able to delete themselves / auto-scaling


Chronological Thread 
  • From: Sascha Bates < >
  • To: Brad Knowles < >
  • Cc: Chris Chalfant < >,
  • Subject: [chef-dev] Re: Re: clients able to delete themselves / auto-scaling
  • Date: Tue, 15 May 2012 18:09:21 -0400

If you already have queuing in place, you could have the deletion process publish to a queue that is subscribed to by a deleter. Lots of lightweight messaging options out there these days.

On 5/15/12 6:07 PM, Brad Knowles wrote:
On May 15, 2012, at 1:00 PM, Chris Chalfant wrote:

You can also write a knife plugin that compares the list of nodes known to 
the chef server and compare that list to the output of 
ec2-describe-instances. Anything that's in chef but not in ec2-desc can be 
queued for node/client deletion. You can run this as a cron job on your chef 
server or some other management node if you are using hosted chef.
For my previous employer, I wrote a shell script that basically did the same sort of 
thing.  However, I kept running into edge cases where the code needed to be modified so 
that it didn't accidentally blow away clients of one sort or another -- like the 
$COMPANY-validator client, the -dev clients that we spun up with Chef and then did a 
"knife node delete" so that we couldn't accidentally re-run chef-client and 
wipe out development work that had been done, etc….


Be careful when developing tools that automatically delete stuff from your 
infrastructure.

Trust me, you *REALLY* don't want to delete the wrong clients.  #BTDT

--
Brad 
Knowles< >
LinkedIn Profile:<http://tinyurl.com/y8kpxu>




Archive powered by MHonArc 2.6.16.

§