/vpc-subnet-calculator

Calculate subnet ranges for a given VPC CIDR range

Primary LanguagePythonMIT LicenseMIT

VPC Subnet Calculator

Build Status Coverage Status

Basic Python script to calculate subnets from a VPC CIDR range.

For now it just grabs the maximum allowable space for a tier of private subnets and then, using the remaining space, carves out the maximum allowable space for a tier of public subnets.

The intention is that this should be usable as an external data source for Terraform before I work out how to reimplement this in Go so it can be a native data source.

TODO:

  • Add Terraform external data source compatible input/output
  • Configurable number of "tiers" of subnets
  • Dynamically get number of AZs for region from AWS
  • IPv6 compatibility