On internal networks, behind a VPC, developers might want to interact with a private API gateway. One typical use case is calling the API gateway to access a certain lambda function from a network resource that needs to make non-internet HTTPS calls without involving the AWS API.
According to the
Full Solution
- On the VPC, create a
- On the VPC Endpoints, explore the Subnets section of the VPC endpoint created in step 1 and grab the IPs
- Create a TLS target group using the IPs from step 3.
- Create a TLS internal NLB, using the target group from step 4.
- Create a custom domain name in API Gateway (Regional type) but point it to the private API gateway.
- On Route53, configure a private zone attached to the same VPC with a CNAME record that points to the NLB DNS address.
Once this is done, it should work. I have done this many times in different projects but keep forgetting about it, so I figured it was a good time to document it to be useful for someone else.
SOCIAL SHARE CARD GENERATOR