Class: VagrantPlugins::Ec2setup::Config
- Inherits:
-
Object
- Object
- VagrantPlugins::Ec2setup::Config
- Defined in:
- lib/vagrant/ec2setup/config.rb
Constant Summary collapse
- DEFAULT_VALUES =
{ key_pair_name: 'vagrant', region: 'ap-northeast-1', private_key_path: '~/.ssh/id_rsa', security_group_name: 'default' }
Instance Method Summary collapse
- #finalize! ⇒ Object
-
#initialize ⇒ Config
constructor
A new instance of Config.
Constructor Details
#initialize ⇒ Config
Returns a new instance of Config.
14 15 16 17 18 |
# File 'lib/vagrant/ec2setup/config.rb', line 14 def initialize DEFAULT_VALUES.keys.each do |name| instance_variable_set("@#{name}", UNSET_VALUE) end end |
Instance Method Details
#finalize! ⇒ Object
20 21 22 23 24 |
# File 'lib/vagrant/ec2setup/config.rb', line 20 def finalize! DEFAULT_VALUES.each do |k, v| instance_variable_set("@#{k}", v) if instance_variable_get("@#{k}") == UNSET_VALUE end end |