cloudnloud / weekly-cloud-engineer-interview-program

12-week-cloud-engineer-program
34 stars 3 forks source link

Purpose of "terraform.tfstate.backup" file ??? #12

Open kkeyan688 opened 1 year ago

kkeyan688 commented 1 year ago

1.Pls explain what's the purpose of "terraform.tfstate.backup" file. ?**

2. Should we need to save "terraform.tfstate.backup" file on any cloud repository as a restricted access inorder to have a 'Backup-Copy" & also can be restore to actual project if in case it's got deleted accidentally/ intentionally ?**

===================================== Thanks CloudnLoud team !!!

image

bsrinivasanCbe commented 1 year ago

The file terraform.tfstate.backup is not created by the User actually, it is the part of the process implementation of terraform. This file is meant for terraform to use incase of it needs for to sync up with cloud provider.

Probably the 2nd question was answered in next session (Day 4) so handle it with dynamo db for remote access and can be imposed with IAM.