使用以下 bash 命令进行部署时:gcloud functions deploy my_gcf --runtime python37 --trigger-http --memory=512MB --region europe-west1 --service-account=my-service-account@my-project.iam.gserviceaccount.com --allow-unauthenticated --verbosity debug我不断得到:FunctionsError: OperationError: code=13, message=Function deployment failed due to a health check failure. This usually indicates that your code was built successfully but failed during a test execution. Examine the logs to determine the cause.不幸的是,在检查日志时,除了以下内容之外,我没有得到任何特别的信息:Error: function terminated. Recommended action: inspect logs for termination reason. Function cannot be initialized.正如您所看到的,我指定了 --verbosity 标志,但它似乎没有一点帮助。所有软件包均已安装,并且我已按照此处的文档构建存储库:在我的代码中,我既有一个requirements.txt文件,也有我编码的自定义软件包,但我想我会从该错误中得到另一种错误多于。我的要求.txt:beautifulsoup4==4.8.0boto==2.49.0boto3==1.13.25botocore==1.16.25cachetools==4.1.0cloudpickle==0.8.1flask==1.0.2flask-restplus==0.12.1functions-framework==2.0.0gensim==3.8.3google-api-core==1.17.0google-api-python-client==1.7.8google-auth==1.15.0google-auth-httplib2==0.0.3google-auth-oauthlib==0.4.1google-cloud==0.34.0google-cloud-core==0.29.1google-cloud-pubsub==0.45.0google-cloud-storage==1.14.0google-cloud-vision==1.0.0grpc-google-iam-v1==0.12.3grpcio==1.29.0gunicorn==19.9.0jinja2==2.10jsonschema==3.2.0more-itertools==8.3.0nltk==3.4.4numpy==1.18.4pandas==1.0.3protobuf==3.12.1requests==2.23.0requests-oauthlib==1.3.0scikit-learn==0.23.1scikit-plot==0.3.7scipy==1.4.1setuptools==46.4.0tempurllib3==1.25.9werkzeug==0.14.1yarl==1.4.2
1 回答
长风秋雁
TA贡献1757条经验 获得超7个赞
即使当前日志不提供任何附加信息,删除时:
werkzeug==0.14.1
并将其替换为:
werkzeug
我能够部署 Google Cloud Function。
添加回答
举报
0/150
提交
取消