3 ms·
Yes you can... assuming your config is a map, include a key for "provider", and set it appropriately. EG in your example for multiple AWS accounts, define provi
by clipradiowallet 5y ago
Yes you can... assuming your config is a map, include a key for "provider", and set it appropriately. EG in your example for multiple AWS accounts, define providers aliased as `aws.account1`, `aws.account2`, and so on. Reference those provider aliases in your map you are iterating through, and set the provider to that value.
- throwaway894345 5y agoI'm 99% sure that will fail with an error because "provider" can't be set dynamically. See this issue, for example: https://github.com/hashicorp/terraform/issues/24476 https://github.com/hashicorp/terraform/issues/24476