- Harder to secure access to the bucket in a team setting
- cross-account state access becomes tricky
- Lots of terraform config maintenance to set access to the bucket
- Error prone and no validation in case of s3
- Lack of versioning and no ability to rollback easily
Drawbacks of Using S3 for Terraform State | Mitigations / Best Practices |
---|---|
Harder to secure access to the bucket in a team setting | Using RBAC policies have fine-grained control on who has access to state in the team, integratable with SSO |
Cross-account state access becomes tricky | For CI jobs a token can be used regardless of where the terraform resources are provisioned |
Lots of Terraform config maintenance to set access to the bucket | Supports cloud block so straightforward to integrate with all terraform/opentofu states |
Error prone and no validation in case of S3 | Cloud block comes with validations to protect from mistakes |
Lack of versioning and no ability to rollback easily | state manager supports versioning and rollbacks out of the box |