func ParseImageName(image string) (ImageName, error) {
	ret := ImageName{}

	img, err := registry.ParseImage(image)
	if err != nil {
		return ret, err
	}

	ret.Registry = img.Domain
	ret.Name = img.Path
	ret.Digest = img.Digest.String()
	ret.Tag = img.Tag

	return ret, nil
}
func ParseImageName(image string) (ImageName, error) {
	ret := ImageName{}

	img, err := registry.ParseImage(image)
	if err != nil {
		return ret, err
	}

	ret.Registry = img.Domain
	ret.Name = img.Path
	ret.Digest = img.Digest.String()
	ret.Tag = img.Tag

	return ret, nil
}
// ParseImageName parses a docker image into an ImageName struct.