whitebear
whitebear

Reputation: 12423

Put lambda in VPC and subnet

I have lambda function which needs to access RDS in isolated private subnet.

And lambda function also need to access internet endpoint and be invoked from internet.

In this case,

However ,,, is it possible to invoke lambda function in private subnet from internet?

(I can set API gateway to the lambda in private subnet?)

Upvotes: 1

Views: 631

Answers (1)

Mark B
Mark B

Reputation: 200446

"However ,,, is it possible to invoke lambda function in private subnet from internet?"

Yes, you always invoke Lambda from the AWS API, which is on the public Internet. Then AWS creates an instance of your Lambda function to handle the invocation. You never make a direct network connection to a Lambda function. It doesn't matter if your Lambda function is configured to run inside your VPC, you still invoke it the same way.

Upvotes: 3

Related Questions