Class: Vagrant::Smartos::Zones::Action::VirtualBox::PlatformISO
- Inherits:
-
Object
- Object
- Vagrant::Smartos::Zones::Action::VirtualBox::PlatformISO
- Includes:
- Helper
- Defined in:
- lib/vagrant/smartos/zones/action/virtualbox/platform_iso.rb
Instance Attribute Summary collapse
-
#app ⇒ Object
Returns the value of attribute app.
-
#env ⇒ Object
Returns the value of attribute env.
-
#machine ⇒ Object
Returns the value of attribute machine.
Instance Method Summary collapse
- #call(env) ⇒ Object
-
#initialize(app, _env) ⇒ PlatformISO
constructor
A new instance of PlatformISO.
Constructor Details
#initialize(app, _env) ⇒ PlatformISO
Returns a new instance of PlatformISO.
13 14 15 |
# File 'lib/vagrant/smartos/zones/action/virtualbox/platform_iso.rb', line 13 def initialize(app, _env) @app = app end |
Instance Attribute Details
#app ⇒ Object
Returns the value of attribute app.
12 13 14 |
# File 'lib/vagrant/smartos/zones/action/virtualbox/platform_iso.rb', line 12 def app @app end |
#env ⇒ Object
Returns the value of attribute env.
12 13 14 |
# File 'lib/vagrant/smartos/zones/action/virtualbox/platform_iso.rb', line 12 def env @env end |
#machine ⇒ Object
Returns the value of attribute machine.
12 13 14 |
# File 'lib/vagrant/smartos/zones/action/virtualbox/platform_iso.rb', line 12 def machine @machine end |
Instance Method Details
#call(env) ⇒ Object
17 18 19 20 21 22 23 24 25 26 27 28 |
# File 'lib/vagrant/smartos/zones/action/virtualbox/platform_iso.rb', line 17 def call(env) @env = env @machine = env[:machine] if requires_platform_iso? env[:ui].warn 'Remapping platform ISO' machine.provider_config.customizations << remove_dvddrive machine.provider_config.customizations << add_platform_image end @app.call(env) end |