You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to implement the AWS lambda function packaging as a docker container image as explained in the blog, and I am getting the error below when I test the function invocation with this command: curl -XPOST "http://localhost:9000/2015-03-31/functions/function/invocations" -d '{}'. What could be the problem?
{"errorType":"Runtime.ImportModuleError","errorMessage":"Error: Cannot find module '/var/task/node_modules/faker/index.js'. Please verify that the package.json has a valid "main" entry","trace":["Runtime.ImportModuleError: Error: Cannot find module '/var/task/node_modules/faker/index.js'. Please verify that the package.json has a valid "main" entry"," at _loadUserApp (/var/runtime/UserFunction.js:100:13)"," at Object.module.exports.load (/var/runtime/UserFunction.js:140:17)"," at Object. (/var/runtime/index.js:43:30)"," at Module._compile (internal/modules/cjs/loader.js:999:30)"," at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)"," at Module.load (internal/modules/cjs/loader.js:863:32)"," at Function.Module._load (internal/modules/cjs/loader.js:708:14)"," at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:60:12)"," at internal/main/run_main_module.js:17:47"]}
The text was updated successfully, but these errors were encountered:
I am trying to implement the AWS lambda function packaging as a docker container image as explained in the blog, and I am getting the error below when I test the function invocation with this command: curl -XPOST "http://localhost:9000/2015-03-31/functions/function/invocations" -d '{}'. What could be the problem?
{"errorType":"Runtime.ImportModuleError","errorMessage":"Error: Cannot find module '/var/task/node_modules/faker/index.js'. Please verify that the package.json has a valid "main" entry","trace":["Runtime.ImportModuleError: Error: Cannot find module '/var/task/node_modules/faker/index.js'. Please verify that the package.json has a valid "main" entry"," at _loadUserApp (/var/runtime/UserFunction.js:100:13)"," at Object.module.exports.load (/var/runtime/UserFunction.js:140:17)"," at Object. (/var/runtime/index.js:43:30)"," at Module._compile (internal/modules/cjs/loader.js:999:30)"," at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)"," at Module.load (internal/modules/cjs/loader.js:863:32)"," at Function.Module._load (internal/modules/cjs/loader.js:708:14)"," at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:60:12)"," at internal/main/run_main_module.js:17:47"]}
The text was updated successfully, but these errors were encountered: