Module: Jets::Stack::Parameter::Dsl
- Extended by:
- ActiveSupport::Concern, Memoist
- Included in:
- Jets::Stack
- Defined in:
- lib/jets/stack/parameter/dsl.rb
Instance Method Summary collapse
- #add_common_parameters ⇒ Object
- #add_depends_on_parameters ⇒ Object
-
#dependency_outputs(dependency) ⇒ Object
Returns output keys associated with the stack.
- #parameters ⇒ Object
Instance Method Details
#add_common_parameters ⇒ Object
13 14 15 16 |
# File 'lib/jets/stack/parameter/dsl.rb', line 13 def add_common_parameters self.class.parameter(:iam_role) self.class.parameter(:s3_bucket) end |
#add_depends_on_parameters ⇒ Object
18 19 20 21 22 23 24 25 |
# File 'lib/jets/stack/parameter/dsl.rb', line 18 def add_depends_on_parameters depends_on = self.class.depends_on depends_on.each do |dependency| dependency_outputs(dependency).each do |output| self.class.parameter(output) end end if depends_on end |
#dependency_outputs(dependency) ⇒ Object
Returns output keys associated with the stack. They are the resource logical ids.
29 30 31 |
# File 'lib/jets/stack/parameter/dsl.rb', line 29 def dependency_outputs(dependency) dependency.to_s.camelize.constantize.output_keys end |
#parameters ⇒ Object
7 8 9 10 11 |
# File 'lib/jets/stack/parameter/dsl.rb', line 7 def parameters add_common_parameters add_depends_on_parameters Parameter.definitions(self.class) end |