Menu

1 / 18

How to associate an EC2 instance with a custom VPC

DEV Community: aws·Rodolfo Henrique·9 days ago
#g6IY2jvX
#devtoaws#devto#dev#subnet#instance
Reading 0:00
15s threshold

Before we begin, a quick note: the screenshots in this tutorial are in Brazilian Portuguese (pt-BR). However, the navigation flow, configuration options, and steps follow the same logic in the English version of the AWS Console. Sorry for any inconvenience, and I hope you enjoy the tutorial!

Portuguese version: Como associar uma instância EC2 a uma VPC personalizada

In this lab you create an isolated network in AWS and launch an EC2 instance inside it. When you finish, three resources are tied together: VPC VPC-01 , subnet my-subnet-01 , and instance my-server . The instance should not land in the account's default network.

A VPC (Virtual Private Cloud) is the virtual network for your account in one Region. You define the IP address range, the subnets, and the traffic rules. An EC2 instance does not "connect to the cloud" in the abstract. It gets a network interface, and that interface has to live in a subnet. The subnet belongs to a VPC.

AWS already creates a default VPC in each Region.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.