gpt4 book ai didi

google-app-engine - 将 Hugo 站点部署到 GAE 结果为 "internal error 13"

转载 作者:IT王子 更新时间:2023-10-29 01:47:42 25 4
gpt4 key购买 nike

我一直在为 App Engine 上的博客托管暂存设置,并且有几十个版本运行良好。我的 main.go 文件非常简单,但尝试部署时会在命令行出现“内部错误”:

You may also view the gcloud log file, found at
[/Users/id/.config/gcloud/logs/2016.11.28/10.18.23.292328.log].
File upload done.
Updating service [default]...failed.
ERROR: (gcloud.app.deploy) Error Response: [13] An internal error occurred.

日志文件的最后一 block 对于错误原因没有帮助:

2016-11-28 10:18:50,133 DEBUG    root            Operation [apps/blog-149523/operations/2a31964d-4f0c-4c1c-9fd7-844d36be257f] complete. Result: {
"metadata": {
"target": "apps/blog-149523/services/default/versions/20161128t101823",
"method": "google.appengine.v1beta5.Versions.CreateVersion",
"user": "ian.douglas@iandouglas.com",
"insertTime": "2016-11-28T17:18:34.140Z",
"endTime": "2016-11-28T17:18:47.381Z",
"@type": "type.googleapis.com/google.appengine.v1beta5.OperationMetadataV1Beta5"
},
"done": true,
"name": "apps/blog-149523/operations/2a31964d-4f0c-4c1c-9fd7-844d36be257f",
"error": {
"message": "An internal error occurred.",
"code": 13
}
}
2016-11-28 10:18:50,134 DEBUG root (gcloud.app.deploy) Error Response: [13] An internal error occurred.
Traceback (most recent call last):
File "/Users/id/src/public/google-cloud-sdk/lib/googlecloudsdk/calliope/cli.py", line 740, in Execute
resources = args.calliope_command.Run(cli=self, args=args)
File "/Users/id/src/public/google-cloud-sdk/lib/googlecloudsdk/calliope/backend.py", line 1648, in Run
resources = command_instance.Run(args)
File "/Users/id/src/public/google-cloud-sdk/lib/surface/app/deploy.py", line 53, in Run
return deploy_util.RunDeploy(args, app_create=True)
File "/Users/id/src/public/google-cloud-sdk/lib/googlecloudsdk/command_lib/app/deploy_util.py", line 410, in RunDeploy
all_services)
File "/Users/id/src/public/google-cloud-sdk/lib/googlecloudsdk/command_lib/app/deploy_util.py", line 257, in Deploy
endpoints_info)
File "/Users/id/src/public/google-cloud-sdk/lib/googlecloudsdk/api_lib/app/appengine_api_client.py", line 119, in DeployService
return operations.WaitForOperation(self.client.apps_operations, operation)
File "/Users/id/src/public/google-cloud-sdk/lib/googlecloudsdk/api_lib/app/api/operations.py", line 70, in WaitForOperation
encoding.MessageToPyValue(completed_operation.error)))
OperationError: Error Response: [13] An internal error occurred.
2016-11-28 10:18:50,135 ERROR root (gcloud.app.deploy) Error Response: [13] An internal error occurred.
2016-11-28 10:18:50,501 DEBUG root Metrics reporting process started...

搜索“内部错误 13”让我得到了很多答案,即使是在 SO 上,也说这是一个“暂时性”错误,应该会自行消失,但我已经处理这个问题超过一周。

我尽可能地简化了我的 main.go,但无济于事:

package main

import (
"net/http"
"fmt"
)

func init() {
http.HandleFunc("/_ah/health", func(w http.ResponseWriter, r *http.Request) { fmt.Fprintf(w, "OK") })
http.Handle("/", http.FileServer(http.Dir("public")))
}

但是部署过程并没有提示我的 Go 代码不好,它只是每次都抛出这个模糊的内部错误 13,而且我找不到任何关于它是真正的服务器端还是我做过的事情的信息。

感谢您的帮助!

最佳答案

我的路径中一定有一个命名不当的 .md 文件。将此添加到我的 app.yaml 解决了问题:

skip_files:
- ^(.*/)?.*\.md$

如果 gcloud 系统能告诉我更清楚一点就好了!

关于google-app-engine - 将 Hugo 站点部署到 GAE 结果为 "internal error 13",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40850308/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com