Lesson 1 of 4 ยท Build a Cloud Foundation
Networks and address spaces
A virtual network gives your cloud resources a private address space. Choose a CIDR range that leaves room for future subnets and does not overlap with networks you may need to connect later.
Example
resource "aws_vpc" "main" {
cidr_block = "10.0.0.0/16"
tags = { Name = "training-network" }
}Step by step
- Choose a private CIDR range.
- Leave room for separate public and private areas.
- Document the network purpose.
- Avoid overlapping connected networks.
Common mistakes to avoid
- Choosing a CIDR range without considering future subnets.
- Reusing an address range that overlaps with an office or VPN network.