首页 > 解决方案 > Google Cloud appengine 部署:未找到应用

问题描述

我继承了一个使用 google appengine 的 php 代码库,所以我在本地有一个完全构建的应用程序,我正在尝试部署它。但是当我运行时:

gcloud app deploy --project project-name --verbosity=debug

我收到以下错误。我不明白暂存命令错误,因为我在 app.yaml 中指定了runtime: php55. 我不知道 API 端点错误是什么意思,我也不明白为什么没有找到应用程序。对于任何这些错误的任何帮助将不胜感激。

调试:使用参数运行 [gcloud.app.deploy]:[--project: "project-name", --verbosity: "debug"] 调试:未找到运行时 [php55] 和环境 [STANDARD] 的暂存命令。调试:API 端点:[ https://appengine.googleapis.com/],API 版本:[v1] 调试:未找到应用程序:回溯(最后一次调用):文件“/Users/myname/Downloads/google-cloud-sdk/lib/googlecloudsdk/command_lib/app/deploy_util.py”,行679,在 _PossiblyCreateApp 返回 api_client.GetApplication() 文件“/Users/myname/Downloads/google-cloud-sdk/lib/googlecloudsdk/api_lib/app/appengine_api_client.py”,第 66 行,在 GetApplication 返回 self.client.apps。获取(请求)文件“/Users/myname/Downloads/google-cloud-sdk/lib/googlecloudsdk/third_party/apis/appengine/v1/appengine_v1_client.py”,第 1124 行,在获取配置、请求、global_params=global_params)文件中“/Users/myname/Downloads/google-cloud-sdk/lib/third_party/apitools/base/py/base_api.py”,第 722 行,_RunMethod return self.ProcessHttpResponse(method_config, http_response,请求)文件“/Users/myname/Downloads/google-cloud-sdk/lib/third_party/apitools/base/py/base_api.py”,第728行,在ProcessHttpResponse self.__ProcessHttpResponse(method_config,http_response,request)文件“ /Users/myname/Downloads/google-cloud-sdk/lib/third_party/apitools/base/py/base_api.py",第 599 行,在 __ProcessHttpResponse http_response,method_config=method_config,request=request) HttpNotFoundError:HttpError 访问在 __ProcessHttpResponse http_response, method_config=method_config, request=request) HttpNotFoundError: HttpError 访问在 __ProcessHttpResponse http_response, method_config=method_config, request=request) HttpNotFoundError: HttpError 访问 https://appengine.googleapis.com/v1/apps/project-name?alt=json:响应:<{'status': '404', 'content-length': '136', 'x-xss-protection ':'0','x-content-type-options':'nosniff','transfer-encoding':'chunked','vary':'Origin,X-Origin,Referer','server':'ESF ', '-content-encoding': 'gzip', 'cache-control': 'private', 'date': 'Tue, 24 Sep 2019 22:49:44 GMT', 'x-frame-options': ' SAMEORIGIN', 'alt-svc': 'quic=":443"; 马=2592000;v="46,43"', '内容类型': '应用程序/json; charset=UTF-8'}>, 内容 <{
"error": { "code": 404, "

标签: google-app-enginegoogle-cloud-sdk

解决方案


的值--project必须对应于 Google Cloud Platform 项目 ID。

目前尚不清楚您是否在粘贴问题时替换了您的实际项目 ID(NB 项目 ID 和项目名称是不同的属性,请参阅链接) 。project-name

验证项目是否存在的一种方法是:

gcloud projects describe [[PROJECT]]

假设项目存在,第二个考虑因素是(因为您没有指定deployables),该命令假定工作目录包含一个app.yaml(App Engine 应用程序配置)文件。


推荐阅读