【问题标题】:Google App Engine Resource Error on the Django Deployment TutorialDjango 部署教程中的 Google App Engine 资源错误
【发布时间】:2020-10-10 07:47:24
【问题描述】:

我一直在寻找一种部署 Django 应用程序的好方法,我发现 Google App Engine Flex 是一个非常好的解决方案。我在应用程序部署方面没有太多经验,所以我跟随Official Google Tutorial 了解部署。

在最后一步,教程指示我在 cmd 提示符下部署应用程序:gcloud app deploy

我跟着。在我收到此消息之前,一切似乎都很好:

正在更新服务 [默认](这可能需要几分钟)...

过了一会儿,我收到了这条消息:

Updating service [default] (this may take several minutes)...failed.
ERROR: (gcloud.app.deploy) Error Response: [13] Flex operation <stuff..> error [INTERNAL]: An internal error occurred while processing task /app-engine-flex/insert_flex_deployment/flex_create_resources>2020-10-10T07:36:04.734Z7747.ue.0: Deployment Manager operation <stuff..> errors: [code: "RESOURCE_ERROR"
location: "<stuff...>"
message: "{\"ResourceType\":\"compute.beta.regionAutoscaler\",\"ResourceErrorCode\":\"403\",\"ResourceErrorMessage\":{\"code\":403,\"message\":\"The caller does not have permission\",\"status\":\"PERMISSION_DENIED\",\"statusMessage\":\"Forbidden\",\"requestPath\":\"<stuff..>",\"httpMethod\":\"POST\"}}"
]

每次我重新运行命令 gcloud app deploy 时,我都会得到完全相同的错误。知道如何解决吗? Google 搜索没有向我透露任何信息。

【问题讨论】:

    标签: python django google-app-engine google-cloud-platform


    【解决方案1】:

    首先尝试给自己以下权限。 This 的回答将有助于一些解释。

    另外,请尝试在您的 .yaml 文件中添加以下内容,看看是否可以解决问题

    automatic_scaling:
        min_num_instances: 1
        max_num_instances: 7    
    

    【讨论】:

    • 哇,将这些行添加到 app.yaml 中实际上修复了它。
    • 太棒了。似乎是由于扩展实例。其中一个错误实际上并不代表错误是什么。
    猜你喜欢
    • 2011-10-07
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2023-03-30
    • 2021-09-25
    相关资源
    最近更新 更多