我们正在$DAYJOB
使用基于 Go 1.9 的 AppEngine 应用程序。现在 Google 正在弃用 1.9 版,我正在尝试使用迁移指南迁移到 1.11 。它说我应该设置runtime: go111
和删除 的api_version: go1.9
值app.yaml
,但是这样做时,我收到一条错误消息部署:
ERROR: (gcloud.app.deploy) Staging command [/usr/lib/google-cloud-sdk/platform/google_appengine/go-app-stager /home/peter/src/licensemanager/src/web/app.yaml /home/peter/src/licensemanager/src/web /home/peter/tmp/tmpBB3Yk8/tmpQQPTFj] failed with return code [1].
------------------------------------ STDOUT ------------------------------------
------------------------------------ STDERR ------------------------------------
2019/08/21 07:59:20 invalid api_version value
--------------------------------------------------------------------------------
如果我尝试将其添加回来,无论我输入什么值,我都会收到一条错误消息:
╔════════════════════════════════════════════════════════════╗
╠═ Uploading 12 files to Google Cloud Storage ═╣
╚════════════════════════════════════════════════════════════╝
File upload done.
ERROR: (gcloud.app.deploy) INVALID_ARGUMENT: The following fields are not allowed in app.yaml: api_version.
我在这里有点茫然,我做错了什么?
在本地运行dev_appserver.py
工作正常。