2
0
mirror of https://github.com/acepanel/panel.git synced 2026-02-04 11:27:17 +08:00

fix(容器): 镜像拉取

This commit is contained in:
耗子
2024-03-16 16:24:43 +08:00
parent 26d8aacabd
commit 89a6c3733b

View File

@@ -278,7 +278,13 @@ func (r *Container) ImagePull(config requests.ImagePull) error {
options.RegistryAuth = authStr
}
_, err := r.client.ImagePull(context.Background(), config.Name, options)
out, err := r.client.ImagePull(context.Background(), config.Name, options)
if err != nil {
return err
}
defer out.Close()
_, err = io.Copy(io.Discard, out)
return err
}