fix image download timout

This commit is contained in:
wanyaoqi
2019-07-03 17:28:32 +08:00
parent 2f7086e17b
commit 6fe2a6938f
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -271,7 +271,7 @@ func (region *SRegion) CreateImage(zoneId string, imageName, format, osType, des
header.Add("X-IMAGE-UUID", image.UUID)
header.Add("X-IMAGE-SIZE", fmt.Sprintf("%d", size))
header.Add("Content-Type", body.FormDataContentType())
resp, err := httputils.Request(httputils.GetDefaultClient(), context.Background(), "POST", image.BackupStorageRefs[0].InstallPath, header, body, false)
resp, err := httputils.Request(httputils.GetTimeoutClient(0), context.Background(), "POST", image.BackupStorageRefs[0].InstallPath, header, body, false)
if err != nil {
return nil, err
}