Next, we need to secure the EC2 instances in both environments. First, let’s create security groups for the EC2 instance in the development environment.
Security section of the VPC console
We will enter the following settings for the security group of the EC2 instance in the development environment:
dev-ec2-sgAllow SSH and other private connectionsdevelopment-vpc
Next, create a security group for the EC2 instance in the production environment:
prod-ec2-sgAllow SSH and other private connectionsproduction-vpc10.1.0.0/16 (Dev VCP)imga-nlb-sg in below
In image, I forget to add the second Inbound Rule :D
Once created, we now have the two desired security groups.
Finally, setup SG for Load Balancer and other resources
Allow SSH and other private connectionsproduction-vpcprod-ec2-sg
Re-check
