Class: VagrantPlugins::ProviderLocal::Action::Create
- Inherits:
-
Object
- Object
- VagrantPlugins::ProviderLocal::Action::Create
- Defined in:
- lib/vagrant-local/action/create.rb
Overview
This will create the Instance
Instance Method Summary collapse
- #call(env) ⇒ Object
-
#initialize(app, _env) ⇒ Create
constructor
A new instance of Create.
Constructor Details
#initialize(app, _env) ⇒ Create
Returns a new instance of Create.
12 13 14 15 |
# File 'lib/vagrant-local/action/create.rb', line 12 def initialize(app, _env) @logger = Log4r::Logger.new('vagrant_local::action::import') @app = app end |
Instance Method Details
#call(env) ⇒ Object
17 18 19 20 21 22 23 |
# File 'lib/vagrant-local/action/create.rb', line 17 def call(env) @machine = env[:machine] @driver = @machine.provider.driver @machine.id = SecureRandom.uuid @driver.install(env[:ui]) @app.call(env) end |