You can read this AWS official documentation and see my notes as following.
With my understanding, the flow seems:
Lambda function --> private subnet --> NAT Gateway --> public subnet --> Internet Gateway
With above flow, it could help to understand and config it.
PS: public subnet & private subnet
A public subnet is a subnet that’s associated with a route table that has a route to an internet gateway, while a private subnet does not.
No Comments