IaC - practice of defining and managing infrastructure using code files (ARM templates, Terraform files) Flashcards

(5 cards)

1
Q

What is IaC?

A

IaC is the practice of defining and managing infrastructure (storage, VM’s, cloud services, switches) using code files—such as ARM templates, Terraform files, or Ansible playbooks—instead of configuring resources manually (e.g. in Azure portal).

For example using a Terraform (HCL) script that provisions/sets-up a VM without needing to click around in the Azure portal.

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

What are the benefits of Infrastructure as Code (IaC)?

A

Benefits of IaC:
+speed = can setup complex infrastructure in seconds (after you have created the template/script)
+consistency = eliminates human error - same code always gives same output
+scalability = it’s easy to replicate/scale horizontally - just deploy the code again X times as needed
+Version Control = you can track changes and rollback Version if needed
+Automation = integrate IaC with CI/CD for fully automated deployments
+Cost-management = can spin down services as desired to save compute (reduce opex/cloud spending)

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

What is the difference between a Terraform template and a Terraform script?

A

A Terraform template is a HCL file that defines the desired infrastructure (like a blueprint), while a Terraform script typically refers to code that automates running Terraform commands (like init, plan, apply)—often using shell or CI/CD tools.

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

What does declaratively mean?

A

Declaratively means describing what you want the end state to be, not step-by-step how to achieve it (imperatively). The system figures out the steps to reach that state.

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

What is Terraform?

A

Terraform is an open-source Infrastructure as Code (IaC) tool by HashiCorp that lets you define, provision, and manage cloud infrastructure declaratively using a simple language called HCL (HashiCorp Configuration Language). HCL is based on JSON but is more human-readable.

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