Sha256: c2821c1d55707708f81792f3d46718a2fbbe13a0bc10683fff44939745618671

Contents?: true

Size: 528 Bytes

Versions: 4

Compression:

Stored size: 528 Bytes

Contents

require 'linecook/commands/vbox_command'

module Linecook
  module Commands
    
    # :startdoc::desc stop a vm
    #
    # Stops one or more VirtualBox virtual machines using 'poweroff'.  By
    # default all virtual machines configured in config/ssh will be stopped.
    #
    class Stop < VboxCommand
      def process(*hosts)
        vm_names = resolve_vm_names(hosts)
        each_vm_name(vm_names) do |vm_name|
          if running?(vm_name)
            stop(vm_name)
          end
        end
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
linecook-1.2.1 lib/linecook/commands/stop.rb
linecook-1.2.0 lib/linecook/commands/stop.rb
linecook-1.1.0 lib/linecook/commands/stop.rb
linecook-1.0.0 lib/linecook/commands/stop.rb