Class: Topo::Provision::MachineImageGenerator
- Inherits:
-
MachineGenerator
- Object
- ResourceGenerator
- MachineGenerator
- Topo::Provision::MachineImageGenerator
- Defined in:
- lib/topo/provision/generators/machine_image.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#lazy_attributes ⇒ Object
readonly
Returns the value of attribute lazy_attributes.
-
#machine_options ⇒ Object
readonly
Returns the value of attribute machine_options.
-
#normal_attributes ⇒ Object
readonly
Returns the value of attribute normal_attributes.
Attributes inherited from ResourceGenerator
#name, #resource_attributes, #resource_type, #undeploy_action
Instance Method Summary collapse
-
#initialize(data) ⇒ MachineImageGenerator
constructor
A new instance of MachineImageGenerator.
Methods inherited from MachineGenerator
Methods inherited from ResourceGenerator
#default_action, #default_resource_template, #deploy, #do_action, #template, #template_root_dir, #undeploy
Methods included from Topo::ParseGen
#convert_keys_to_sym, #convert_keys_to_sym_deep, #expand_ref, #lazy_attribute_to_s, #topo_refs, #value_from_path
Constructor Details
#initialize(data) ⇒ MachineImageGenerator
Returns a new instance of MachineImageGenerator.
31 32 33 34 35 36 37 38 39 |
# File 'lib/topo/provision/generators/machine_image.rb', line 31 def initialize(data) @resource_type ||= "machine_image" super @name = data['name'] + "_image" @template_base_name = "machine" # Note: specific driver may need to convert image options to symbols opts = data['provisioning']['image_options'] @resource_attributes["image_options"] = opts if opts end |
Instance Attribute Details
#lazy_attributes ⇒ Object (readonly)
Returns the value of attribute lazy_attributes.
29 30 31 |
# File 'lib/topo/provision/generators/machine_image.rb', line 29 def lazy_attributes @lazy_attributes end |
#machine_options ⇒ Object (readonly)
Returns the value of attribute machine_options.
29 30 31 |
# File 'lib/topo/provision/generators/machine_image.rb', line 29 def @machine_options end |
#normal_attributes ⇒ Object (readonly)
Returns the value of attribute normal_attributes.
29 30 31 |
# File 'lib/topo/provision/generators/machine_image.rb', line 29 def normal_attributes @normal_attributes end |