Open julian-fh opened 3 years ago
Specifying a custom runtime image for a function results in this error: ServerlessError: Unable to read handler file in function .... This error also occurs if the file exists.
ServerlessError: Unable to read handler file in function ...
Example: serverless.yml
functions: sentimentanalysis: image: immortalfaas/sentiment name: sentimentanalysis handler: handler.main
I suspect, that a recent change in the serverless framework causes this error. The packaging gets interrupted, if a image is specified in a function. This seems to be introduced to enable AWS Lambda image support. https://github.com/serverless/serverless/blame/96735db3d4c08e18ca5c0b632fb0993e766a6894/lib/plugins/package/lib/packageService.js#L117
image
However, in serverless-openwhisk, this causes a failure of the packaging (and therefore the deployment).
A quick fix might be renaming image: to something like runtime_image:
image:
runtime_image:
Specifying a custom runtime image for a function results in this error:
ServerlessError: Unable to read handler file in function ...
. This error also occurs if the file exists.Example: serverless.yml
I suspect, that a recent change in the serverless framework causes this error. The packaging gets interrupted, if a
image
is specified in a function. This seems to be introduced to enable AWS Lambda image support. https://github.com/serverless/serverless/blame/96735db3d4c08e18ca5c0b632fb0993e766a6894/lib/plugins/package/lib/packageService.js#L117However, in serverless-openwhisk, this causes a failure of the packaging (and therefore the deployment).
A quick fix might be renaming
image:
to something likeruntime_image: