I keep getting this error after running yarn serverless offline
in my docker/nodejs image running inside an aws lambda function. I have a hunch it has to do with readonly lambda file system.
: Load command deploy
Serverless: Load command deploy:function
Serverless: Load command deploy:list
Serverless: Load command deploy:list:functions
Serverless: Load command invoke
Serverless: Load command invoke:local
Serverless: Load command info
Serverless: Load command logs
Serverless: Load command metrics
Serverless: Load command print
Serverless: Load command remove
Serverless: Load command rollback
Serverless: Load command rollback:function
Serverless: Load command slstats
Serverless: Load command plugin
Serverless: Load command plugin
Serverless: Load command plugin:install
Serverless: Load command plugin
Serverless: Load command plugin:uninstall
Serverless: Load command plugin
Serverless: Load command plugin:list
Serverless: Load command plugin
Serverless: Load command plugin:search
Serverless: Load command config
Serverless: Load command config:credentials
Serverless: Load command rollback
Serverless: Load command rollback:function
Serverless: Load command upgrade
Serverless: Load command uninstall
Serverless: Load command offline
Serverless: Load command offline:start
Serverless: Load command login
Serverless: Load command logout
Serverless: Load command generate-event
Serverless: Load command test
Serverless: Load command dashboard
Serverless: Load command output
Serverless: Load command output:get
Serverless: Load command output:list
Serverless: Load command param
Serverless: Load command param:get
Serverless: Load command param:list
Serverless: Load command studio
Serverless: Error: ENOENT: no such file or directory, open '/home/sbx_user1051/.serverlessrc.1568800362'
at Object.openSync (fs.js:462:3)
at Function.writeFileSync [as sync] (/backend/node_modules/write-file-atomic/index.js:205:13)
at storeConfig (/backend/node_modules/@serverless/utils/config.js:50:21)
at createDefaultGlobalConfig (/backend/node_modules/@serverless/utils/config.js:72:3)
at getGlobalConfig (/backend/node_modules/@serverless/utils/config.js:129:10)
at getConfig (/backend/node_modules/@serverless/utils/config.js:134:24)
at Object.getLoggedInUser (/backend/node_modules/@serverless/utils/config.js:188:18)
at module.exports (/backend/node_modules/@serverless/enterprise-plugin/lib/isAuthenticated.js:5:44)
at ServerlessEnterprisePlugin.asyncInit (/backend/node_modules/@serverless/enterprise-plugin/lib/plugin.js:541:7)
at /backend/node_modules/serverless/lib/classes/PluginManager.js:648:82
at Array.map (<anonymous>)
at PluginManager.asyncPluginInit (/backend/node_modules/serverless/lib/classes/PluginManager.js:648:39)
at PluginManager.loadAllPlugins (/backend/node_modules/serverless/lib/classes/PluginManager.js:125:17)
at Serverless.init (/backend/node_modules/serverless/lib/Serverless.js:166:30)
at processTicksAndRejections (internal/process/task_queues.js:97:5)
at /backend/node_modules/serverless/scripts/serverless.js:73:7
Serverless: Unable to store serverless config: /home/sbx_user1051/.serverlessrc due to ENOENT error
Error --------------------------------------------------
Error: ENOENT: no such file or directory, mkdir '/home/sbx_user1051'
Get Support --------------------------------------------
Docs: docs.serverless.com
Bugs: github.com/serverless/serverless/issues
Issues: forum.serverless.com
Your Environment Information ---------------------------
Operating System: linux
Node Version: 12.20.2
Framework Version: 2.25.2 (local)
Plugin Version: 4.4.3
SDK Version: 2.3.2
Components Version: 3.7.0
error Command failed with exit code 1.