Class: ResourceIn::RacktablesDriver
- Defined in:
- lib/resource_in/driver_racktables.rb
Constant Summary
Constants inherited from Driver
Driver::DETAIL_FORMAT, Driver::FORMAT, Driver::VALID_PATTERN
Instance Method Summary collapse
- #get_lastupdate(vm) ⇒ Object
-
#initialize ⇒ RacktablesDriver
constructor
A new instance of RacktablesDriver.
Methods inherited from Driver
Constructor Details
#initialize ⇒ RacktablesDriver
Returns a new instance of RacktablesDriver.
6 7 8 9 |
# File 'lib/resource_in/driver_racktables.rb', line 6 def initialize @cmd_lastupdate = 'get_vm_lastupdate' @cachepath = '/tmp/cache.racktables' end |
Instance Method Details
#get_lastupdate(vm) ⇒ Object
10 11 12 |
# File 'lib/resource_in/driver_racktables.rb', line 10 def get_lastupdate(vm) invoke("#{@cmd_lastupdate} '#{vm}'", @cachepath + ".last_update.#{vm}") end |