我无法使用 Visual Studio 2019 中的 Google Cloud Platform 工具将 App Engine 应用程序发布到 GCloud

Djg*_*588 4 c# asp.net google-app-engine gcloud

我刚刚将我的应用程序转移到在 .Net Core 3.1 上使用 ASP.Net。我之前使用的是 NodeJS 和 Express。我安装了适用于 Visual Studio 的 Google Cloud Platform 工具,使用项目上的右键菜单生成了 app.yaml 和 Dockerfile,将 app.yaml 修改为我认为有效的配置,并尝试发布它。我选择了 App Engine Flex,选择了我的项目,然后收到一条“所选 GCP 项目需要先启用服务才能部署。启用服务”消息。单击“启用服务”(看起来像一个链接)不会执行任何操作。这阻止了我发布我的应用程序,这有点烦人。

任何帮助将不胜感激 :)

应用程序.yaml

service: api
runtime: custom
env: flex
env_variables:
    ASPNETCORE_ENVIROMENT: "production"
instance_class: F2
automatic_scaling:
    min_idle_instances: 0
    max_idle_instances: 2
    min_pending_latency: 15ms
    max_pending_latency: 100ms
Run Code Online (Sandbox Code Playgroud)

Dockerfile

FROM gcr.io/google-appengine/aspnetcore:3.1
COPY . /app
WORKDIR /app
ENTRYPOINT ["dotnet", "Project Phoenix Game Services.dll"]
Run Code Online (Sandbox Code Playgroud)

Mit*_*áti 6

启用 App Engine 管理 API。