mdneuzerling / lambdr

Run R containers on AWS Lambda
https://lambdr.mdneuzerling.com
Other
131 stars 12 forks source link

Error Testing image Built. #26

Closed noob100000 closed 1 year ago

noob100000 commented 1 year ago

Hi. Thanks for making this package!!

I am facing an issue when I test using Curl. Things I have done: I first built the image using the Dockerfile provided in the example section in readme.md file. So, basically there is Dockerfile and runtime.R in my folder.

After I have built the image, I run this command: docker run -p 9000:8080 docker-image:test (docker-image:test is changed accordingly)

In a new terminal when I run the command: curl "http://localhost:9000/2015-03-31/functions/function/invocations" -d '{"number":10}'

I am getting this error: image

Could someone please help ?

noob100000 commented 1 year ago

Update: When I test it on AWS console and also invoke in AWS CLI using base 64 encoded json, I am getting correct output. But locally testing as per this doc https://docs.aws.amazon.com/lambda/latest/dg/images-test.html is not working. Anyways closing it.