floydspace / serverless-esbuild

💨 A Serverless framework plugin to bundle JavaScript and TypeScript with extremely fast esbuild
MIT License
445 stars 137 forks source link

Function level `runtime` parameter does not work. #548

Open privatejava opened 2 months ago

privatejava commented 2 months ago

Describe the bug Currently, I started a simple serverless project that contains the runtime: node20.x trying to deploy for AWS. But it only works if the runtime is defined in the provider level. If I use it in the function level only then it fails.

To Reproduce Set runtime: nodejs20.x at function level only and remove runtime from provider.

Then Run sls package

Expected behavior It should work in any level of runtime definition.

Screenshots or Logs 2024-08-02_14-38

Versions (please complete the following information):