
Answer-first summary for fast verification
Answer: !FindInMap [ MapName, TopLevelKey, SecondLevelKey ]
!FindInMap [ MapName, TopLevelKey, SecondLevelKey ] - The intrinsic function Fn::FindInMap returns the value corresponding to keys in a two-level map that is declared in the Mappings section. YAML Syntax for the full function name: Fn::FindInMap: [ MapName, TopLevelKey, SecondLevelKey ] Short form of the above syntax is : !FindInMap [ MapName, TopLevelKey, SecondLevelKey ] Where, MapName - Is the logical name of a mapping declared in the Mappings section that contains the keys and values. TopLevelKey - The top-level key name. Its value is a list of key-value pairs. SecondLevelKey - The second-level key name, which is set to one of the keys from the list assigned to TopLevelKey.
Author: LeetQuiz Editorial Team
Ultimate access to all questions.
As part of your project, you are tasked with creating a CloudFormation template to deploy a Content Management System (CMS) application that runs on an EC2 instance within your AWS account. Given that this application will be deployed across multiple AWS regions, you need to generate a map that includes all the possible values for the base Amazon Machine Images (AMIs) specific to each region.
What is the method you would use to invoke the !FindInMap function to accomplish this objective?
A
!FindInMap [ MapName, TopLevelKey, SecondLevelKey, ThirdLevelKey ]
B
!FindInMap [ MapName, TopLevelKey ]
C
!FindInMap [ MapName ]
D
!FindInMap [ MapName, TopLevelKey, SecondLevelKey ]
No comments yet.