Sorry for the late reply. How are you managing the remote state in this case? We manage each environment on different AWS accounts. As per my knowledge, we can't use different remote s3 bucket for each terraform workspace.
Afaik, switching terraform workspaces creates completely independent state files. I usually commit them to a private git repo. Probably not the best solution, but it works for me.
Sorry for the late reply. How are you managing the remote state in this case? We manage each environment on different AWS accounts. As per my knowledge, we can't use different remote s3 bucket for each terraform workspace.
Afaik, switching terraform workspaces creates completely independent state files. I usually commit them to a private git repo. Probably not the best solution, but it works for me.
Alternatively have a look at terragrunt, it solves the exact same problem you described.
I have just started using terragrunt. It solves the exact problem.
Thanks for the tip about Terragrunt. Looks super handy.