nodejs httprequest with data - getting error getaddrinfo ENOENT

后端 未结 8 1702
天命终不由人
天命终不由人 2020-12-02 22:47

Update - Answered by self

I see one has to make sure that the DNS is resolved properly from the machine, check out the node documentation to make sure that domain

8条回答
  •  不思量自难忘°
    2020-12-02 23:22

    I had a similar issue but running as a AWS Lambda function, so in case someone is having this issue with Lambda functions this is how I got it resolved.

    • Give your Lambda function a VPC.
    • Select at least 2 Subnets.
    • And select a Security Group.

    I spent a day until I found this fix, hope it helps someone else.

提交回复
热议问题