3

Whenever I tried to run the serverless framework offline by using

sls offline

enter image description here

I am getting this warning for every function.

2 Answers2

1

This seems to be an issue with Serverless Offline that has been fixed in a newer release - https://github.com/dherault/serverless-offline/issues/381

Have you tried upgrading Serverless Offline?

Aaron Stuyvenberg
  • 3,437
  • 1
  • 9
  • 21
0

Here I used s-function.json file, And In this file, I changed

"runtime": "nodejs" instade of "nodejs8.10", also add endpoints

"endpoints": [
      {
        "path": "func-name",
        "method": "POST",
        "requestParameters": {
          "htmlContent": true
        },
        "requestTemplates": {
          "application/json": {
            "payload": "$input.json('$')"
          }
        }
      }
  ],

And This works for me.