Class: ClcMachine::SecretDataBag
- Inherits:
-
Object
- Object
- ClcMachine::SecretDataBag
- Defined in:
- lib/clc_machine/secret_data_bag.rb
Instance Method Summary collapse
-
#initialize(stamp) ⇒ SecretDataBag
constructor
A new instance of SecretDataBag.
- #raw ⇒ Object
- #vsphere_password(hypervisor_type = :standard) ⇒ Object
- #vsphere_username(hypervisor_type = :standard) ⇒ Object
Constructor Details
#initialize(stamp) ⇒ SecretDataBag
Returns a new instance of SecretDataBag.
5 6 7 |
# File 'lib/clc_machine/secret_data_bag.rb', line 5 def initialize(stamp) @stamp = stamp end |
Instance Method Details
#raw ⇒ Object
17 18 19 |
# File 'lib/clc_machine/secret_data_bag.rb', line 17 def raw @raw ||= load_secrets end |
#vsphere_password(hypervisor_type = :standard) ⇒ Object
13 14 15 |
# File 'lib/clc_machine/secret_data_bag.rb', line 13 def vsphere_password(hypervisor_type = :standard) raw['hypervisors'][hypervisor_type.to_s]['vsphere_password'] end |
#vsphere_username(hypervisor_type = :standard) ⇒ Object
9 10 11 |
# File 'lib/clc_machine/secret_data_bag.rb', line 9 def vsphere_username(hypervisor_type = :standard) raw['hypervisors'][hypervisor_type.to_s]['vsphere_username'] end |