Networking project: set up the infra for outbound traffic from an EC2 instance inside a private subnet in a VPC to be possible with NAT Gateway

AWS Project: VPC with a public subnet containing a NAT gateway. The NAT gateway can be used for outbound traffic to the internet from the EC2 instance in the private subnet.  A route table connects the destination 0.0.0.0/0 to the internet gateway for the public subnet. In the public subnet, there is an EC2 instance…