- Newest
- Most votes
- Most comments
Hi, don't you have a naming issue of your image like the one reported in https://github.com/serverless/serverless/issues/8636 when you use it in the Lambda ?
In this case, the user combined :latest with @sha and it creates a problem like yours
Best,
Didier
I'm experiencing the exact same issue. I’ve tried using different versions of the AWS Python base image, and the Python code only includes the handler returning a string. However, I keep encountering the The provided image is invalid error regardless. I’ve also tried increasing both the memory and storage allocations, but to no avail. Are Python images not supported for Lambda? Generally, AWS provides more meaningful error messages that can help resolve the issue, but this one is not very informative.
FROM public.ecr.aws/lambda/python:3.11
COPY lambda_function.py ${LAMBDA_TASK_ROOT}
CMD [ "lambda_function.handler" ]
and the python lambda_function.py file has this. import sys def handler(event, context): return 'Hello from AWS Lambda using Python' + sys.version + '!'*
EDIT My machine: windows 10, using Podman and build with --platform linux/amd64
After looking to the state of the function, I found this.
"State": "Failed",
"StateReason": "ImageLayerFailure: UnsupportedImageLayerDetected - Layer Digest sha256:ac49b43c92d795a3c4559f8668db011267a10e7e3e3799b70050e887e4032d85",
"StateReasonCode": "InvalidImage",
Hi, I wanted to follow up on this issue. Was this resolved? If so, can you share the solution?
Relevant content
- asked 3 years ago
- asked 9 months ago
- AWS OFFICIALUpdated 9 months ago
- AWS OFFICIALUpdated 8 months ago
- AWS OFFICIALUpdated a year ago