07-CloudFormation Basics Flashcards

1
Q

What is CloudFormation?

A

A tool used to create, update, and delete infrastructure in a consistent and repeatable way using templates. It keeps the logical and physical resources in sync by adding, updating, or deleting resources as defined in the template.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What formats are used for CloudFormation templates?

A

YAML or JSON

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What are the components of CloudFormation?

A

Resources, Stacks, Description, Template Format Version, Metadata, Parameters, Mappings, Conditions, and Outputs.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What parts of a CloudFormation template are mandatory?

A

Only the resource section is mandatory.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is the Resource portion of a CloudFormation template?

A

Defines the infrastructure resources to be created, updated, or deleted.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What are logical resources in a template?

A

Representations of infrastructure components (e.g., AWS::EC2::Instance).

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What purpose do logical resources provide when deploying a template?

A

The translate to the physical resources that are created.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What happens to a resource if it is removed from a template?

A

The corresponding physical resource is deleted when the updated template is deployed.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What are Stacks?

A

A collection of logical resources managed by CloudFormation? Stacks are created when deploying the template for the first time.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What is the Description of a template?

A

Optional text field that provides details about the template.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

If a Description is used alongside a Template Format Version, which one goes first?

A

The Template Format Version and the Description must immediately follow.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What is a Template Format Version?

A

Specifies the version of the template structure.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What is the Metadata of a template?

A

Controls how a template is presented in the Console and is used to enhance the user experience, especially in larger templates.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What are Parameters in a template?

A

User inputs that can be promoted for when applying a template. Parameters can also have default values and created for valid entries.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What is an example of a Parameter?

A

instance size, AZ

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

NAME?

A

Optional section used to create lookup tables.

17
Q

What is an example of a Mapping?

A

Mapping regions and instance types to specific AMIs based on the environment, such a test or production.

18
Q

What are Conditions in a template?

A

Allows for conditional logic in a template, can be created based on parameters and used to control resource creation.

19
Q

What is an example of a Condition?

A

Creating resources only in production environments if a parameter equals “prod”.

20
Q

What are Outputs?

A

Return information after the stack creation or update, such as an instance ID or a WordPress URL.

21
Q

Why are Outputs useful?

A

Useful to retrieving important information about the resources created.