Class: Mccloud::Command::LbCommand

Inherits:
GroupBase
  • Object
show all
Defined in:
lib/mccloud/command/lb.rb

Instance Attribute Summary

Attributes inherited from GroupBase

#env

Instance Method Summary collapse

Methods inherited from GroupBase

#initialize, register

Methods included from Helpers

#initialize_environment

Constructor Details

This class inherits a constructor from Mccloud::Command::GroupBase

Instance Method Details

#associate(selection = nil) ⇒ Object



16
17
18
19
20
21
22
23
# File 'lib/mccloud/command/lb.rb', line 16

def associate(selection=nil)
  env.config.providers.each do |name,provider|
    env.logger.debug("Asking provider #{name} to associate lb #{selection}")
    provider.on_selected_components("lb",selection) do |id,lb|
      lb.associate(options)
    end
  end
end

#list(selection = nil) ⇒ Object



8
9
10
11
12
13
# File 'lib/mccloud/command/lb.rb', line 8

def list(selection=nil)
    env.config.providers.each do |name,provider|
      env.logger.debug("Asking provider #{name} to list lb #{selection}")
      provider.lb_list(selection,options)
    end
end

#sorry(selection = nil) ⇒ Object



26
27
28
29
30
31
32
33
# File 'lib/mccloud/command/lb.rb', line 26

def sorry(selection=nil)
  env.config.providers.each do |name,provider|
    env.logger.debug("Asking provider #{name} to sorry lb #{selection}")
    provider.on_selected_components("lb",selection) do |id,lb|
      lb.sorry(options)
    end
  end
end