IaC
IaC is operational practice to turn your infrastructure requirements into code (scripts) in order to automate it. This allows you to consistently provision or patch new resources without making mistakes.
There are also no-code and low-code tools available for this.
Paradigms
Like coding IaC falls into different paradigms. Since, it is code as well (kind of).
IaC can be plain Imperative in nature, where you specify step-by-step what needs to be executed, or Declarative where you specify the requirement as a configuration, leaving it up to the tool to figure out what needs to be done.
Imperative IaC
- More scripting knowledge required
- More control (small changes, optimization, software quirks)
Doesn't scale that well
- Less idempotent
- More Explicit -> needs to change for different scenarios
Declarative IaC
-
Highly idempotent
-
Not explicit => Accommodates Operations#Configuration Drift smoothly
-
Less control
-
Overkill for small fixes/updates