Class: VagrantPlugins::Vmck::Config
- Inherits:
-
Object
- Object
- VagrantPlugins::Vmck::Config
- Defined in:
- lib/vagrant-vmck/config.rb
Instance Attribute Summary collapse
-
#cpus ⇒ Object
Returns the value of attribute cpus.
-
#image_path ⇒ Object
Returns the value of attribute image_path.
-
#memory ⇒ Object
Returns the value of attribute memory.
-
#name ⇒ Object
Returns the value of attribute name.
-
#private_key_path ⇒ Object
Returns the value of attribute private_key_path.
-
#restrict_network ⇒ Object
Returns the value of attribute restrict_network.
-
#storage ⇒ Object
Returns the value of attribute storage.
-
#vmck_url ⇒ Object
Returns the value of attribute vmck_url.
Instance Method Summary collapse
- #finalize! ⇒ Object
-
#initialize ⇒ Config
constructor
A new instance of Config.
Constructor Details
#initialize ⇒ Config
Returns a new instance of Config.
13 14 15 16 17 18 19 20 21 22 |
# File 'lib/vagrant-vmck/config.rb', line 13 def initialize @vmck_url = UNSET_VALUE @private_key_path = UNSET_VALUE @memory = UNSET_VALUE @cpus = UNSET_VALUE @image_path = UNSET_VALUE @storage = UNSET_VALUE @name = UNSET_VALUE @restrict_network = UNSET_VALUE end |
Instance Attribute Details
#cpus ⇒ Object
Returns the value of attribute cpus.
7 8 9 |
# File 'lib/vagrant-vmck/config.rb', line 7 def cpus @cpus end |
#image_path ⇒ Object
Returns the value of attribute image_path.
8 9 10 |
# File 'lib/vagrant-vmck/config.rb', line 8 def image_path @image_path end |
#memory ⇒ Object
Returns the value of attribute memory.
6 7 8 |
# File 'lib/vagrant-vmck/config.rb', line 6 def memory @memory end |
#name ⇒ Object
Returns the value of attribute name.
10 11 12 |
# File 'lib/vagrant-vmck/config.rb', line 10 def name @name end |
#private_key_path ⇒ Object
Returns the value of attribute private_key_path.
5 6 7 |
# File 'lib/vagrant-vmck/config.rb', line 5 def private_key_path @private_key_path end |
#restrict_network ⇒ Object
Returns the value of attribute restrict_network.
11 12 13 |
# File 'lib/vagrant-vmck/config.rb', line 11 def restrict_network @restrict_network end |
#storage ⇒ Object
Returns the value of attribute storage.
9 10 11 |
# File 'lib/vagrant-vmck/config.rb', line 9 def storage @storage end |
#vmck_url ⇒ Object
Returns the value of attribute vmck_url.
4 5 6 |
# File 'lib/vagrant-vmck/config.rb', line 4 def vmck_url @vmck_url end |
Instance Method Details
#finalize! ⇒ Object
24 25 26 27 28 29 30 31 32 33 |
# File 'lib/vagrant-vmck/config.rb', line 24 def finalize! @vmck_url = nil if @vmck_url == UNSET_VALUE @private_key_path = nil if @private_key_path == UNSET_VALUE @memory = 512 if @memory == UNSET_VALUE @cpus = 1 if @cpus == UNSET_VALUE @image_path = 'imgbuild-master.qcow2.tar.gz' if @image_path == UNSET_VALUE @storage = nil if @storage == UNSET_VALUE @name = 'default' if @name == UNSET_VALUE @restrict_network = false if @restrict_network == UNSET_VALUE end |