[chef] Re: Re: Re: Re: Re: Re: Chef Search Again


Chronological Thread 
  • From: Douglas Garstang < >
  • To:
  • Subject: [chef] Re: Re: Re: Re: Re: Re: Chef Search Again
  • Date: Tue, 16 Jun 2015 14:17:35 -0700

Thanks all.

Here's my solution...

aws ec2 describe-instances --region us-east-1 --filter "Name=tag:role,Values=role-zookeeper" "Name=tag:environment,Values=dev" "Name=instance-state-name,Values=running" --query 'Reservations[].Instances[].Tags[?Key==`Name`].Value[]'

throw that in a ohai plugin, convert the output to json, and I'm good to go.

Doug.


On Tue, Jun 16, 2015 at 2:10 PM, Lamont Granquist < " target="_blank"> > wrote:
On 6/16/15 1:32 PM, Douglas Garstang wrote:

5. It's vagrant. Chef solo. There is no client.pem file as far as I know.
Chef-solo doesn't have a server to talk to in order to node.save or post results to search.  The node.save turns into a NOP transparently in chef-solo.  You can go down the road of chef-solo-search but then eventually data bags will troll you.  At some point people wind up trying to write a stub chef-server for chef-solo to talk to and replace all the APIs which is just going to fight with all the special cases of chef-solo to make it NOT talk to a server which are littered around the codebase.

The correct way forwards is to use chef-zero instead of chef-solo and have a normal fully functional chef-client that expects to talk to a chef server talking to the chef-zero server.  Otherwise you will continue to fight the tool.

+1 on using Chef Server 12 and/or Hosted Chef with Solr 4 which will get the required sleep down from a couple minutes to a couple seconds.

You can also use an overrride run list instead of -r to run a recipe without updating the run_list.




--



Archive powered by MHonArc 2.6.16.

§