In order to create multiple CloudFront distros in aws I need to use the following details:
I have a list of prefixes (api1, api2, api3), and I have several domains (example1.com, example2.com) - I counted the prefixes and the domains by different amounts on purpose.
To do so I thought I might need to use dynamic blocks this way:
certificates = [
domain = [“example1.com”, “example2.com”]
prefix = [“api1”, “api2”, “api3”]
and then configure the resource with 2 dynamic blocks (One for each list) but it seems like it’s not the way I need to implement it as the variable in the content section shouldn’t be a list…
Hope you guys can help me with a hint.
The expected behavior should be a CloudFront distro for every mix:
api1 .example1 .com
api2 .example1 .com
api3 .example1 .com
api1 .example2 .com
api2 .example2 .com
api3 .example2 .com