Module: Jets::Stack::Dsl::Main::Base
- Defined in:
- lib/jets/stack/dsl/main/base.rb
Instance Method Summary collapse
-
#code_s3_key ⇒ Object
Due to ‘if Jets::Stack.has_resources?` check early on in the bootstraping process The code has not been built at that point.
- #depends_on(*stacks) ⇒ Object
-
#get_att(*item) ⇒ Object
Examples: get_attr(“logical_id.attribute”) get_attr(“logical_id”, “attribute”) get_attr([“logical_id”, “attribute”]).
-
#handler(name) ⇒ Object
resource(:hello, function_name: “hello”, code: { s3_bucket: “!Ref S3Bucket”, s3_key: code_s3_key }, description: “Hello world”, handler: handler_function(“hello.lambda_handler”), memory_size: 128, role: “!Ref IamRole”, runtime: “python3.6”, timeout: 20, ).
- #logical_id(value) ⇒ Object
- #ref(value) ⇒ Object
Instance Method Details
#code_s3_key ⇒ Object
Due to ‘if Jets::Stack.has_resources?` check early on in the bootstraping process The code has not been built at that point. So we use a placeholder and will replace the placeholder as part of the cfn template build process after the code has been built and the code_s3_key with md5 is available.
23 24 |
# File 'lib/jets/stack/dsl/main/base.rb', line 23 def code_s3_key end |
#depends_on(*stacks) ⇒ Object
16 17 |
# File 'lib/jets/stack/dsl/main/base.rb', line 16 def depends_on(*stacks) end |
#get_att(*item) ⇒ Object
Examples:
get_attr("logical_id.attribute")
get_attr("logical_id", "attribute")
get_attr(["logical_id", "attribute"])
10 11 |
# File 'lib/jets/stack/dsl/main/base.rb', line 10 def get_att(*item) end |
#handler(name) ⇒ Object
resource(:hello,
function_name: "hello",
code: {
s3_bucket: "!Ref S3Bucket",
s3_key: code_s3_key
},
description: "Hello world",
handler: handler_function("hello.lambda_handler"),
memory_size: 128,
role: "!Ref IamRole",
runtime: "python3.6",
timeout: 20,
)
39 40 |
# File 'lib/jets/stack/dsl/main/base.rb', line 39 def handler(name) end |
#logical_id(value) ⇒ Object
13 14 |
# File 'lib/jets/stack/dsl/main/base.rb', line 13 def logical_id(value) end |
#ref(value) ⇒ Object
3 4 |
# File 'lib/jets/stack/dsl/main/base.rb', line 3 def ref(value) end |