AWS SAM + Lambda not bundling properly.
Hi guys. I'm writing an AWS SAM template in which I am setting up Prisma with my Lambda functions to interact with my RDS Postgres DB. I am facing an error that I suspect might be related to the query engine and prisma.schema not being bundled with the code. The error I am getting is:
Clearly theres an issue with the client being generated for my local machine rather than the lambda. I even tried this in my prisma client instatiation but no luck:
I also tried setting this in the lambda's environment variables:
PRISMA_QUERY_ENGINE_LIBRARY: /opt/nodejs/node_modules/.prisma/client/libquery_engine-rhel-openssl-1.0.x.so.node
(Deps in layers)
Any help would be appreciated. Cheers!0 Replies