Infrastructure as code (IaC) is a practice that automates the provisioning and management of IT infrastructure by using configuration files rather than manual processes. IaC treats infrastructure as software. It is used to version, test and deploy infrastructure by using the same practices used for application code.
This approach enables us to bypass traditional manual configuration, which can be cumbersome and error-prone. Manual configuration often involves individual server setup, console-based management and undocumented changes. Instead, we define infrastructure requirements in configuration files that specify the resources needed—servers, networks, databases, security policies—and how to configure them.
## Infrastructure as Code Advantages
- Reduces errors
- Increases speed of deployments
- Improves infrastructure consistency
- Eliminates configuration drift
- Reduces cost
## Infrastructure as Code Disadvantages
- Vendor lock-in risk
- Steep learning curve
- Role-based access control troubles
## Popular Infrastructure as Code Tools
- [[Terraform]]
- [AWS CloudFormation](https://aws.amazon.com/cloudformation/)
- [Azure Resource Manager](https://azure.microsoft.com/en-us/get-started/azure-portal/resource-manager)
Sources:
- https://www.ibm.com/think/topics/infrastructure-as-code
- https://aws.amazon.com/what-is/iac/
- https://www.redhat.com/en/topics/automation/what-is-infrastructure-as-code-iac
%% wiki footer: Please don't edit anything below this line %%
## This note in GitHub
<span class="git-footer">[Edit In GitHub](https://github.dev/data-engineering-community/data-engineering-wiki/blob/main/Concepts/Software%20Engineering/Infrastructure%20as%20Code.md "git-hub-edit-note") | [Copy this note](https://raw.githubusercontent.com/data-engineering-community/data-engineering-wiki/main/Concepts/Software%20Engineering/Infrastructure%20as%20Code.md "git-hub-copy-note")</span>
<span class="git-footer">Was this page helpful?
[👍](https://tally.so/r/mOaxjk?rating=Yes&url=https://dataengineering.wiki/Concepts/Software%20Engineering/Infrastructure%20as%20Code) or [👎](https://tally.so/r/mOaxjk?rating=No&url=https://dataengineering.wiki/Concepts/Software%20Engineering/Infrastructure%20as%20Code)</span>