I have a Certificate Authority file (.pem) that i’m bundling with my lambda and I have added the NODE_EXTRA_CA_CERTS
to my environment variables with the path to the cert file. Unfortunately, when i make my requests back to my on-prem server, node is giving the following error:
UNABLE_TO_GET_ISSUER_CERT_LOCALLY
My serverless.yml has an environment variable configured and it shows up with my lambda, for some reason, Node just isn’t picking it up. Doing this locally works:
provider:
name: aws
region: us-east-2
runtime: nodejs12.x
endpointType: regional
stage: dev
environment:
NODE_EXTRA_CA_CERTS: /var/task/.certs/My-Root-CA.pem