Class: Befog::Commands::List
- Inherits:
-
Object
- Object
- Befog::Commands::List
- Includes:
- Mixins::Command, Mixins::Configurable, Mixins::Help, Mixins::Safely, Mixins::Scope, Mixins::Selectable
- Defined in:
- lib/befog/commands/list.rb
Instance Attribute Summary
Attributes included from Mixins::Command
Instance Method Summary collapse
Methods included from Mixins::Help
Methods included from Mixins::Selectable
Methods included from Mixins::Safely
Methods included from Mixins::Scope
#_bank, #account_key, #account_secret, #bank, #bank?, #bank_name, #banks, #compute, #flavor, #flavor?, #get_server, #image, #image?, #keypair, #keypair?, #price, #provider, #provider?, #provider_name, #providers, #region, #region?, #security_group, #security_group?, #servers, #servers=
Methods included from Mixins::Configurable
#_configuration, #configuration, #configuration_name, #configuration_path, included, #save
Methods included from Mixins::Command
#command, #error, included, #initialize, #log, #process_options, #usage
Instance Method Details
#run ⇒ Object
31 32 33 34 35 36 |
# File 'lib/befog/commands/list.rb', line 31 def run run_for_selected do |id| server = compute.servers.get(id) log "%-15s %-15s %-15s %-45s %-10s" % [id,server.flavor_id,server.["Name"],(server.dns_name||"-"),server.state] end end |