INNER CODE UNIT · Go
ptr
iximiuz/cdebug · cmd/exec/exec_docker.go:237
func ptr[T any](v T) *T {
return &v
}
func imageExistsLocally(
ctx context.Context,
client *docker.Client,
image string,
platform string,
) (bool, error) {
imageSummary, _, err := client.ImageInspectWithRaw(ctx, image)
if err != nil {
logrus.Debugf("The image %s (%s) wasn't found locally", image, platform)
return false, nil
}
parts := strings.Split(platform, "/")
if imageSummary.Os != parts[0] {