Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Things you will need are:</p> <ol> <li><a href="http://wiki.opscode.com/display/chef/Launch+Cloud+Instances+with+Knife" rel="nofollow">knife-ec2</a> - This is used to start/stop Amazon EC2 instances.</li> <li><a href="http://wiki.opscode.com/display/chef/Installing+Chef+Server" rel="nofollow">chef-server</a> - To be able to use search in your recipes. It should be also accessible from your EC2 instances.</li> <li><a href="http://wiki.opscode.com/display/chef/Search" rel="nofollow">search</a> - with this you will be able to find among the nodes provisioned by chef, exactly the one you need using different queries.</li> </ol> <p>I have lately written an article <a href="http://dracoater.blogspot.com/2012/09/how-to-run-dynamic-cloud-tests-with-800.html" rel="nofollow">How to Run Dynamic Cloud Tests with 800 Tomcats, Amazon EC2, Jenkins and LiveRebel</a>. It involves loadbalancer installation and loadbalancer must know all IP adresses of the servers it balances. You can check out the <a href="https://github.com/DracoAter/lr-cluster/blob/master/cookbooks/tomcat/recipes/lr-tomcat.rb" rel="nofollow">recipe of balanced node</a>, how it looks for loadbalancer:</p> <pre><code>search(:node, "roles:lr-loadbalancer").first </code></pre> <p>And check out the <a href="https://github.com/DracoAter/lr-cluster/blob/master/cookbooks/apache2/recipes/default.rb" rel="nofollow">loadbalancer recipe</a>, how it looks for all the balanced nodes and updates the apache config file:</p> <pre><code>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 =&gt; lr_nodes) notifies :restart, 'service[apache2]' end </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload