Hi all,

I wish to specify an app server as "spare" - to be out of the load  
balancer rotation. I specified as so:

role :app, '192.168.10.99', :spare => true # machines out of load  
balancer rotation

The task is like this:

   namespace :loadbalancer do
     desc 'Remove "spare" machines from load balancer rotation by  
removing public/healthcheck/balancer (to be run just before  
apache:reload)'
     task :set, :roles => :app, :only => { :spare => true } do
       run("rm -f #{release_path}/public/healthcheck/balancer")
     end
   end

----------------------
The problem is that in some environments (we use what I think is  
called multistage) there is no spare machine (i..e, staging) and so I  
would configure no machine as designated as spare:

        role :app, '192.168.10.99'

When I do this I see this error:

`deploy:loadbalancer:set' is only run for servers matching  
{:roles=>:app, :only=>{:spare=>true}}, but no servers matched

----------------------
So, I designated a "blank" machine as spare:
role :app, '', :spare => true # NO machines out of load balancer  
rotation

When I run the task, I know see this command being run:
   servers: ["192.168.10.90", ""]
followed by an error indiocating it could not ssh into machine due to  
an authentication error.
In other words, cap is trying to shh into a blank IP address.
--------------------

Seems like there should be a way to have 'spare' specified in some  
configs and not in others - any one know how?

Mike

-- 
* You received this message because you are subscribed to the Google Groups 
"Capistrano" group.
* To post to this group, send email to [email protected]
* To unsubscribe from this group, send email to 
[email protected] For more options, visit this group at 
http://groups.google.com/group/capistrano?hl=en

Reply via email to