aws-samples / image-optimization

Simple, performant and cost efficient solution for optimizing images using Amazon CloudFront, Amazon S3 and AWS Lambda
MIT No Attribution
173 stars 106 forks source link

Runtime nodejs12.x error #6

Closed olajiredominic closed 1 year ago

olajiredominic commented 1 year ago

Everytime i run the commands i get this error

Custom::S3AutoDele...ceProvider/Handler Resource handler returned message: "The runtime parameter of nodejs12.x is no longer supported for creating or updating AWS Lam bda functions. We recommend you use the new runtime (nodejs18.x) while creating or updating functions. (Service: Lambda, Status Code: 400, Request ID: 5001..............

olajiredominic commented 1 year ago

Fixed by updating aws-cdk and aws-cdk-lib to their latest versions currently 2.81.0.

achrafsouk commented 1 year ago

Thanks for sharing, glad it worked out!

piotrekwitkowski commented 1 year ago

For future reference: issue has been fixed with commit https://github.com/aws-samples/image-optimization/commit/b01b44bb8582f1e57e2eaf2748aa0f4e638b3b9f. Thanks for bringing our attention to this!