Reputation: 195
I'm developing an AWS architecture for a Retrieval Augmented Generation (RAG) system:
SECURITY
Now, in terms of security, I don't want the system to be exposed to the public Internet (except for the front-end web app, that of course has to be public) therefore I'm putting the RDS MongDB database and all the Lambda functions inside the VPC (I know, technically the Lambda is always inside a VPC owned by the Lambda service, but in this case the Lambda functions are drawn inside my account VPC just to specify that they are configured to access resources in my account VPC). As you can see the connection with the S3 bucket and DynamoDB database is through a VPC Gateway Endpoint. While the connection with Amazon Bedrock service is through VPC Interface Endpoint (AWS PrivateLink).
QUESTION
Now my question is related to the connection between the front-end app and the API Gateway and the Lambda Orchestrator function. In particular, can a public API Gateway endpoint interact with the in-VPC Lambda Orchestrator function? Or do I need to set up an API Gateway private endpoint in the same VPC of the in-VPC Lambda function to allow communication? If I change the API Gateway to be private endpoint, how can I establish communication between the public front-end and the private API Gateway?
Upvotes: 1
Views: 631