Class: Gizzard::RemoveHostCommand

Inherits:
Command
  • Object
show all
Defined in:
lib/gizzard/commands.rb

Instance Attribute Summary

Attributes inherited from Command

#argv, #buffer, #command_options, #global_options, #job_injector, #manager

Instance Method Summary collapse

Methods inherited from Command

classify, #confirm!, #get_base_name, #help!, #initialize, make_job_injector, make_manager, #output, #require_tables, #require_template_options, run

Constructor Details

This class inherits a constructor from Gizzard::Command

Instance Method Details

#runObject



765
766
767
768
769
770
771
# File 'lib/gizzard/commands.rb', line 765

def run
  host = @argv[0].split(":")
  host.unshift nil if host.length == 2
  cluster, hostname, port = *host

  manager.remove_remote_host(hostname, port.to_i)
end