mirror of
https://github.com/containers/podman.git
synced 2025-06-21 01:19:15 +08:00
libpod/image: Use RepoDigests() in Inspect()
To get the more-robust handling from 0f6535cf (libpod/image: Use ParseNormalizedNamed in RepoDigests, 2019-01-08, #2106) here too. Signed-off-by: W. Trevor King <wking@tremily.us>
This commit is contained in:
@ -823,9 +823,9 @@ func (i *Image) Inspect(ctx context.Context) (*inspect.ImageData, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
var repoDigests []string
|
||||
for _, name := range i.Names() {
|
||||
repoDigests = append(repoDigests, strings.SplitN(name, ":", 2)[0]+"@"+i.Digest().String())
|
||||
repoDigests, err := i.RepoDigests()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
driver, err := i.DriverData()
|
||||
|
Reference in New Issue
Block a user