Hi,
I’m new to terragrunt
and I am wondering if it possible for terragrunt to use multiple AWS profiles in the same run.
Given the following workspace dir struct:
terragrunt-workspace/aws/account-dev/terragrunt.hcl
terragrunt-workspace/aws/account-dev/eu-west-1/terragrunt.hcl main.tf ... etc
terragrunt-workspace/aws/account-dev/eu-west-3/terragrunt.hcl main.tf ... etc
terragrunt-workspace/aws/account-prod/terragrunt.hcl
terragrunt-workspace/aws/account-prod/eu-west-1/terragrunt.hcl main.tf ... etc
terragrunt-workspace/aws/account-prod/eu-west-3/terragrunt.hcl main.tf ... etc
terragrunt-workspace/aws/<account>/terragrunt.hcl
looks like:
remote_state {
backend = "s3"
config = {
profile = "<account>"
bucket = "<account>-terragrunt"
key = "${path_relative_to_include()}/terraform.tfstate"
region = "eu-west-3"
encrypt = true
dynamodb_table = "<account>-terragrunt"
}
}
terragrunt-workspace/aws/<account>/<region>/terragrunt.hcl
looks like:
include {
path = find_in_parent_folders()
}
I’m looking for a way to tell terragrunt that is ran from terragrunt-workspace/aws
to use a specific AWS_PROFILE for each account but so far I came up empty.
Regards.