Skip to content

Custom Environment Resources

When creating a new environment with Copilot, you are given the option to import existing VPC resources. (Use flags with env init or the guided experience, shown below.)

% copilot env init
What is your environment's name? env-name
Which credentials would you like to use to create name? [profile default]

  Would you like to use the default configuration for a new environment?
    - A new VPC with 2 AZs, 2 public subnets and 2 private subnets
    - A new ECS Cluster
    - New IAM Roles to manage services and jobs in your environment
  [Use arrows to move, type to filter]
    Yes, use default.
    Yes, but I'd like configure the default resources (CIDR ranges).
  > No, I'd like to import existing resources (VPC, subnets).

When you select the default configuration, Copilot follows AWS best practices and creates a VPC with two public and two private subnets, with one of each type in one of two Availability Zones. While this is a good configuration for most cases, Copilot allows some flexibility when you import your own resources. For example, you may bring a VPC with only two private subnets and no public subnets for your workloads that are not internet-facing. (For more details on the resources you'll need for isolated networks, go here.)

Considerations