[Agent][Operator] - bug fix

This commit is contained in:
zeaslity
2024-05-08 11:12:45 +08:00
parent e7f0d9ea33
commit e56b9bd65c
4 changed files with 22 additions and 5 deletions

View File

@@ -156,6 +156,18 @@ func DownloadCompressUpload(fullNameList []string, shouldGzip bool, gzipFolderFu
fullNameList = slices.DeleteFunc(fullNameList, func(imageName string) bool {
return slices.Contains(errorGzipImageList, imageName)
})
// write to file
targetFile := gzipFolderFullPath + string(os.PathSeparator) + "all-gzip-image-file-name.txt"
for _, gzipFileFullName := range allGzipFileNameList {
utils.AppendContentToFile(
strings.TrimPrefix(gzipFileFullName, gzipFolderFullPath),
targetFile,
)
}
log.InfoF("all gzip file name list is %s", targetFile)
}
// Upload