Due to recent refactoring, I figured out that I need to move some Terraform state items from one S3 path to another. And then to merge configurations with other stuff at the destination directory. Terraform can move state items around, but this feature doesn't work with remote states. Here is one way of doing it. Example Use CaseFirst, let's consider the following situation, this is configuration directory tree output: . ├── db │ └── test │ ├── main.tf (s3 key: aws/db/test/terraform.tfstate) ...
Terraform is my tool of choice for cloud provisioning. The difference compared to the similar tools for cloud provisioning is that Terraform saves the state. Terraform supports AWS and can provision spot instances also. Spot instances are great to save some money in the cloud. They could be used for any service, but it is really hard to manage stateful services like databases. If you have a stateless service spot instances are a great choice. You need to automate spot ...