Tutorials for count and for_each


We’ve recently published tutorials for using count and for_each to provision similar resources, using example configuration to provision AWS EC2 instances and VPCs. These tutorials use the newly-released Terraform 0.13 to provision duplicate modules as well as resources.

First, configure multiple EC2 instances in a VPC using count.

Building on that example, use for_each to provision entire duplicate VPCs for multiple projects.

I hope you enjoy them, and look forward to any questions or feedback you might have!