为什么我可以从非VPC的AWS Lambda调用VPC上的AWS Lambda,反之亦然呢? [英] Why can I call an on-VPC aws lambda from an off-VPC aws lambda but not vice versa?

查看:153
本文介绍了为什么我可以从非VPC的AWS Lambda调用VPC上的AWS Lambda,反之亦然呢?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

因此,如果我有两个Lambda,一个在私有VPC内,一个不在VPC上,则可以从公共Lambda内部调用私有Lambda,但我不能从私有Lambda调用公共Lambda.

So if I have two lambdas, one inside a private VPC, and one not on a VPC, calling the private lambda from inside the public lambda works but I cant call the public from the private lambda.

没有NAT设置.

这是为什么?从理论上讲,我似乎应该不能从公众场合召集私人.

Why is this? It seems that I should not be able to call the private from the public theoretically.

推荐答案

为了触发Lambda函数,所需要做的就是使调用者具有对

In order to trigger a Lambda function, all that's required is for the caller to have outbound access to the Invoke AWS API. It is not necessary for the invoked Lambda function to have any open inbound ports, or any public Internet access.

因此,公共(非VPC,具有Internet访问权限)Lambda函数可以调用Invoke API来触发私有Lambda函数,但是私有VPC(无Internet访问权限)Lambda函数无法访问Invoke API来触发任何Lambda函数.

So a public (non-VPC, has Internet access) Lambda function can call the Invoke API to trigger the private Lambda function, but the private VPC (no Internet access) Lambda function cannot access the Invoke API to trigger any Lambda function.

这篇关于为什么我可以从非VPC的AWS Lambda调用VPC上的AWS Lambda,反之亦然呢?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆