Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8607231
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T03:17:57+00:00 2026-06-12T03:17:57+00:00

I have an environment ( Graphite ) that looks like the following: N worker

  • 0

I have an environment (Graphite) that looks like the following:

  • N worker servers
  • 1 relay server that forwards work to these worker servers
  • 1 web server that can query the relay server.

I would like to use Chef to setup and deploy this environment in EC2 without having to create each worker server individually, get their IPs and set them as attributes in the relay cookbook, create that relay, get the IP, set it as an attribute in the web server cookbook, etc.

Is there a way using chef in which I can make sure that the environment is properly deployed, configured and running without having to set the IPs manually? Particularly, I would like to be able to add a worker server and have the relay update its worker list, or swap the relay server for another one and have the web server update its reference accordingly.

Perhaps this is not what Chef is intended for and is more for per-server configuration and deployment, if that is the case, what would be a technology that facilitates this?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T03:17:59+00:00Added an answer on June 12, 2026 at 3:17 am

    Things you will need are:

    1. knife-ec2 – This is used to start/stop Amazon EC2 instances.
    2. chef-server – To be able to use search in your recipes. It should be also accessible from your EC2 instances.
    3. search – with this you will be able to find among the nodes provisioned by chef, exactly the one you need using different queries.

    I have lately written an article How to Run Dynamic Cloud Tests with 800 Tomcats, Amazon EC2, Jenkins and LiveRebel. It involves loadbalancer installation and loadbalancer must know all IP adresses of the servers it balances. You can check out the recipe of balanced node, how it looks for loadbalancer:

    search(:node, "roles:lr-loadbalancer").first
    

    And check out the loadbalancer recipe, how it looks for all the balanced nodes and updates the apache config file:

    lr_nodes = search(:node, "role:lr-node")
    
    template ::File.join( node[:apache2][:home], 'conf.d', 'httpd-proxy-balancer.conf' ) do
      mode 0644
      variables(:lr_nodes => lr_nodes)
      notifies :restart, 'service[apache2]'
    end
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an environment that doesn't allow server side scripting really (it is extremely
Is it possible for the apache2 user, http, to have environment variables like normal
At my company, we have tiered environment for our web applications (development, staging, production).
Can the TFS proxy be installed on Windows XP? I have an environment that
We have a staged environment with 1 CMS and 3 Slave servers I want
I have Client-Server environment and developed a project for Client-Server. I need to share
I have an environment where multiple sites hosted on the same server will use
I have an environment config file that I'm using to separate dev from staging
I have a environment and I want to know that if I write code
Say I have an environment variable myvar : myvar=\tapple\n When the following command will

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.