1

Basically the above problem. I see no error in the logs, however when I check the script on a seperate server it just works fine. I'm doing an API call to Watson and a simple (get) call to an IFTTT Maker link. I write in Node.js and use the request module.

Is AWS Lambda blocking the connection of HTTPS URL's and if so, what can I do to surpass this unfortunate event? I've already seen a similar issue on another thread which was solved using the request module, but sadly this doesn't work for me.

Any help would be much appreciated.

Billal Begueradj
  • 20,717
  • 43
  • 112
  • 130
  • Did you place the Lambda function inside your VPC? – Mark B Oct 10 '16 at 15:34
  • Please read my answer here. http://stackoverflow.com/questions/39144688/aws-lambda-invoke-not-calling-another-lambda-function-node-js/39206646#39206646 – johni Oct 10 '16 at 19:05

1 Answers1

0

Maybe your Lambda function lives in a private subnet, inside a VPC?

If yes, then it does not have internet access, which means all calls to public servers will time out (see the docs).

In that case, you've got 2 options:

  1. Do not launch your Lambda function inside a VPC.
  2. Allow your private subnet to access the internet by setting up a NAT Gateway. Example guide here.
Eric Eijkelenboom
  • 6,943
  • 2
  • 25
  • 29
  • Sorry for the late reply and thank you for yours. I tried your method, but unfortunately it didn't work. I have made much progress with the VPC's, I created one through the VPC dashboard. According to your guide a NAT gateway is combined with the VPC. So how can I use a NAT gateway and not launch my function inside a VPC? I'm using the Ireland region of Amazon (and thus AWS), while living in Holland, could this be an issue? -> request.get('**'); This entire statement is just skipped (i put console logs in callbacks). I tried several modules. Again, any help would be much appreciated. – Marketing Analist Nov 17 '16 at 13:51