Module: Lab::Controllers::WorkstationController

Included in:
VmController
Defined in:
lib/lab/controller/workstation_controller.rb

Class Method Summary collapse

Class Method Details

.dir_list(basepath = nil) ⇒ Object



11
12
13
14
# File 'lib/lab/controller/workstation_controller.rb', line 11

def self.dir_list(basepath=nil)
  vm_list = Find.find(basepath).select { |f| f =~ /\.vmx$/ }
  return vm_list
end

.running_listObject



5
6
7
8
9
# File 'lib/lab/controller/workstation_controller.rb', line 5

def self.running_list
  vm_list = `vmrun list`.split("\n")
  vm_list.shift
  return vm_list
end