Using sls deploy –package doesn’t work with serverless for google cloud functions

我的梦境 提交于 2019-12-22 00:09:09

问题


I was following the quick start guide for serverless https://serverless.com/framework/docs/providers/google/guide/quick-start/ and created a service as mentioned in the guide. I ran the following commands:

serverless create --template google-nodejs --path my-service
cd my-service
npm install

I edited the serverless.yml to contain a valid key path and tried the following command

serverless package

A .serverless folder was created with myservice.zip file in it. Later I tried to deploy this myservice.zip file using

serverless deploy --package <absolute path of myservice.zip file>

The command failed with the following error: The path argument must be one of type string, Buffer, or URL. Received type undefined

I am wondering if I missed something or serverless doesn’t support deploy --package option for google cloud functions.

My serverless version is 1.44.1

My actual use case is to deploy a prepackaged zipped file to google cloud functions using serverless

来源:https://stackoverflow.com/questions/56390027/using-sls-deploy-package-doesn-t-work-with-serverless-for-google-cloud-function

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!