0
0
AWScloud~10 mins

Nested stacks for modularity in AWS - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the code to define a nested stack resource in AWS CloudFormation.

AWS
Resources:
  NestedStack:
    Type: [1]
    Properties:
      TemplateURL: https://s3.amazonaws.com/mybucket/mytemplate.yaml
Drag options to blanks, or click blank then click option'
AAWS::S3::Bucket
BAWS::CloudFormation::Stack
CAWS::EC2::Instance
DAWS::Lambda::Function
Attempts:
3 left
💡 Hint
Common Mistakes
Using resource types like AWS::S3::Bucket instead of AWS::CloudFormation::Stack.
Confusing nested stack with other AWS resources.
2fill in blank
medium

Complete the code to pass a parameter named 'EnvType' to the nested stack.

AWS
Resources:
  NestedStack:
    Type: AWS::CloudFormation::Stack
    Properties:
      TemplateURL: https://s3.amazonaws.com/mybucket/mytemplate.yaml
      Parameters:
        EnvType: [1]
Drag options to blanks, or click blank then click option'
AProduction
B"Production"
CEnvType
D!Ref EnvType
Attempts:
3 left
💡 Hint
Common Mistakes
Passing a plain string without quotes or intrinsic functions.
Using the parameter name as a string instead of referencing it.
3fill in blank
hard

Fix the error in the nested stack resource by completing the missing property key.

AWS
Resources:
  NestedStack:
    Type: AWS::CloudFormation::Stack
    Properties:
      [1]: https://s3.amazonaws.com/mybucket/mytemplate.yaml
Drag options to blanks, or click blank then click option'
ATemplateBody
BTemplatePath
CTemplateURL
DTemplateFile
Attempts:
3 left
💡 Hint
Common Mistakes
Using TemplateBody instead of TemplateURL for external templates.
Using incorrect property names like TemplatePath or TemplateFile.
4fill in blank
hard

Fill both blanks to define outputs in the nested stack and reference them in the parent stack.

AWS
Resources:
  NestedStack:
    Type: AWS::CloudFormation::Stack
    Properties:
      TemplateURL: https://s3.amazonaws.com/mybucket/mytemplate.yaml
Outputs:
  NestedOutputValue:
    Value: ![1] NestedStack.[2]
Drag options to blanks, or click blank then click option'
AGetAtt
BRef
COutputs
DAttributes
Attempts:
3 left
💡 Hint
Common Mistakes
Using !Ref instead of !GetAtt to access nested stack outputs.
Using wrong keys like Attributes instead of Outputs.
5fill in blank
hard

Fill all three blanks to pass multiple parameters and set the timeout for the nested stack.

AWS
Resources:
  NestedStack:
    Type: AWS::CloudFormation::Stack
    Properties:
      TemplateURL: https://s3.amazonaws.com/mybucket/mytemplate.yaml
      Parameters:
        EnvType: [1]
        InstanceType: [2]
      [3]: 30
Drag options to blanks, or click blank then click option'
A!Ref EnvType
B!Ref InstanceType
CTimeoutInMinutes
DTimeout
Attempts:
3 left
💡 Hint
Common Mistakes
Using plain strings instead of !Ref for parameters.
Using incorrect timeout property names like Timeout.