Modules
- Start writing your configuration with a plan for
modules
. - Use local
modules
to organize and encapsulate your code. - Use the public
Terraform Registry
to find usefulmodules
.
States
-
Backend
-
Instead of using version control, the best way to
manage shared storage
forstate
files is to useTerraform
’s built-in support for remotebackends
. -
A
Terraform
backend
determines howTerraform
loads and storesstate
. -
The default
backend
is the localbackend
, which stores thestate
file on yourlocal disk
. -
Caveats
- In the case of
AWS
, becauseS3 bucket
andDynamoDB table
must be created beforehand, so it poses a chicken-and-egg problem. Separate bootstrap steps are required.
- In the case of
-
-
Workspace
Open Questions
- How to avoid provisioning duplicate resources?