fix wwctl image import --update

This commit is contained in:
Christian Goll
2025-12-11 15:25:56 +01:00
committed by Jonathon Anderson
parent 71345d9c2c
commit f590da4916
4 changed files with 293 additions and 3 deletions

View File

@@ -130,7 +130,8 @@ func ImageImport(cip *wwapiv1.ImageImportParameter) (imageName string, err error
return
}
wwlog.Info("Updating existing image")
} else if strings.HasPrefix(cip.Source, "docker://") || strings.HasPrefix(cip.Source, "docker-daemon://") ||
}
if strings.HasPrefix(cip.Source, "docker://") || strings.HasPrefix(cip.Source, "docker-daemon://") ||
strings.HasPrefix(cip.Source, "file://") || util.IsFile(cip.Source) {
var sCtx *types.SystemContext
sCtx, err = GetSystemContext(cip.OciNoHttps, cip.OciUsername, cip.OciPassword, cip.Platform)