Class: VagrantPlugins::ProviderKvm::Action::InitStoragePool

Inherits:
Object
  • Object
show all
Defined in:
lib/vagrant-kvm/action/init_storage_pool.rb

Overview

Initialize storage pool.

Instance Method Summary collapse

Constructor Details

#initialize(app, env) ⇒ InitStoragePool

Returns a new instance of InitStoragePool.



6
7
8
# File 'lib/vagrant-kvm/action/init_storage_pool.rb', line 6

def initialize(app, env)
  @app = app
end

Instance Method Details

#call(env) ⇒ Object



10
11
12
13
14
15
# File 'lib/vagrant-kvm/action/init_storage_pool.rb', line 10

def call(env)
  # Create a storage pool in tmp_path if it doesn't exist
  Driver::Driver.new.init_storage(env[:tmp_path])

  @app.call(env)
end