Segmentation fault when running wine on AWS Lambda container

0

I have this docker file that displays the wine version:

FROM electronuserland/builder:wine

ENTRYPOINT [ "wine", "--version" ]

When running this on my local docker, it returns the version of wine.

>> docker build -t wine-version .
>> docker run wine-version
>> wine-7.0

but when I uploaded it to AWS ECR and use it as my lambda function container, it printed exited with error: signal: segmentation fault Arch: x86_64

Expectation: wine version should be printed on the logs.

START RequestId: bc7b454b-22c9-4373-aaa3-091c8c4fa17c Version: $LATEST
END RequestId: bc7b454b-22c9-4373-aaa3-091c8c4fa17c
REPORT RequestId: bc7b454b-22c9-4373-aaa3-091c8c4fa17c	Duration: 4.32 ms	Billed Duration: 5 ms	Memory Size: 128 MB	Max Memory Used: 3 MB	
RequestId: bc7b454b-22c9-4373-aaa3-091c8c4fa17c Error: Runtime exited with error: signal: segmentation fault
Runtime.ExitError
  • Were you able to run wine using AWS lambda runtime set up?

已提問 2 年前檢視次數 1247 次
1 個回答
1

You cannot run any docker container as a lambda function.

The docker container has to have either an AWS provided runtime or if you are creating a custom image, then you have to use the open source Lambda Runtime Interface Clients.

Another requirement is that the container image should have lambda code in the format that lambda expects the code to be in.

Have these requirements been met in the container image that you are trying to run as a lambda function?

If you want to learn more about how to run a container image in a lambda function, I will highly recommend this blog - https://aws.amazon.com/blogs/aws/new-for-aws-lambda-container-image-support/

profile pictureAWS
專家
已回答 2 年前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南