Nea*_*mau 7 google-app-engine google-cloud-platform gcloud
我想要一个简单的HelloWorld!部署设置到AppEngine.我正在与另一位朋友/开发人员合作,他的机器上的人能够轻松gcloud app deploy地成功地工作,但是在我的机器上它无法正常工作(经典可以在我的机器上工作).我想知道这是否是我们的存储桶的许可问题,但我和我朋友的AppEngine帐户之间的所有内容都是镜像的.我是我的机智,所以任何帮助都表示赞赏.
我将要描述的内容似乎是互联网上罕见的发现,所以我希望知识渊博的人可以提供帮助.
运行该gcloud app deploy default命令时,我收到以下错误:
Beginning deployment of service [default]...
???????????????????????????????????????????????
?? Uploading 2 files to Google Cloud Storage ??
???????????????????????????????????????????????
File upload done.
Updating service [default]...failed.
ERROR: (gcloud.app.deploy) Error Response: [3] The following errors occurred while copying files to App Engine:
File https://storage.googleapis.com/staging.xxxxxxx.appspot.com/59add2715212c2a5fa68f05ead6ea6a307d279b5 failed with: Conflicting SHA1 sum for file. Expected "90d147b8_dd2137ab_8ec7f19f_c0891006_6585d3de" but received "59add271_5212c2a5_fa68f05e_ad6ea6a3_07d279b5".
Details: [
[
{
"@type": "type.googleapis.com/google.rpc.ResourceInfo",
"description": "Conflicting SHA1 sum for file. Expected \"90d147b8_dd2137ab_8ec7f19f_c0891006_6585d3de\" but received \"59add271_5212c2a5_fa68f05e_ad6ea6a3_07d279b5\".",
"resourceName": "https://storage.googleapis.com/staging.xxxxxxx.appspot.com/59add2715212c2a5fa68f05ead6ea6a307d279b5",
"resourceType": "file"
}
]
]
Run Code Online (Sandbox Code Playgroud)
gcloud init并完成这些说明.gcloud auth application-default login使用我的Google帐户重新运行和验证.的app.yaml
runtime: nodejs10
handlers:
- url: /
static_files: index.html
upload: index.html
Run Code Online (Sandbox Code Playgroud)
的index.html
<html>
<head>
<title>Test Title</title>
</head>
<body>
<p>
Hello from the static index.html file.
</p>
</body>
</html>
Run Code Online (Sandbox Code Playgroud)
问题摘要:Windows 本地计算机文件系统和 Google 云存储中的文本文件大小不同 - SHA 校验和比较失败。
可能的解决方案:
- 在使用Dos2Unix使用 Cigwin部署应用程序之前在本地修复文件,
或从 Linux 部署:
- 将部署文件上传到Cloud Shell并从那里进行部署。
- 将部署文件上传到Linux VM 实例。
有关Windows 和 Unix 互操作性的摘要,请查看文档
| 归档时间: |
|
| 查看次数: |
280 次 |
| 最近记录: |