Skip to content

Commit

Permalink
log error when failed to convert pull secrets
Browse files Browse the repository at this point in the history
Signed-off-by: Kuromesi <[email protected]>
  • Loading branch information
Kuromesi committed Jun 5, 2024
1 parent e814ebb commit 2f77a4d
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 0 deletions.
2 changes: 2 additions & 0 deletions pkg/daemon/criruntime/imageruntime/cri.go
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,8 @@ func (c *commonCRIImageService) pullImageV1(ctx context.Context, imageName, tag
if len(pullErrs) > 0 {
err = utilerrors.NewAggregate(pullErrs)

Check warning on line 155 in pkg/daemon/criruntime/imageruntime/cri.go

View check run for this annotation

Codecov / codecov/patch

pkg/daemon/criruntime/imageruntime/cri.go#L154-L155

Added lines #L154 - L155 were not covered by tests
}
} else {
klog.Errorf("Failed to convert to auth info for registry, err %v", err)

Check warning on line 158 in pkg/daemon/criruntime/imageruntime/cri.go

View check run for this annotation

Codecov / codecov/patch

pkg/daemon/criruntime/imageruntime/cri.go#L157-L158

Added lines #L157 - L158 were not covered by tests
}

// Try the default secret
Expand Down
2 changes: 2 additions & 0 deletions pkg/daemon/criruntime/imageruntime/docker.go
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,8 @@ func (d *dockerImageService) PullImage(ctx context.Context, imageName, tag strin
if len(pullErrs) > 0 {
err = utilerrors.NewAggregate(pullErrs)

Check warning on line 100 in pkg/daemon/criruntime/imageruntime/docker.go

View check run for this annotation

Codecov / codecov/patch

pkg/daemon/criruntime/imageruntime/docker.go#L99-L100

Added lines #L99 - L100 were not covered by tests
}
} else {
klog.Errorf("Failed to convert to auth info for registry, err %v", err)

Check warning on line 103 in pkg/daemon/criruntime/imageruntime/docker.go

View check run for this annotation

Codecov / codecov/patch

pkg/daemon/criruntime/imageruntime/docker.go#L102-L103

Added lines #L102 - L103 were not covered by tests
}

// Try the default secret
Expand Down
2 changes: 2 additions & 0 deletions pkg/daemon/criruntime/imageruntime/pouch.go
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,8 @@ func (d *pouchImageService) PullImage(ctx context.Context, imageName, tag string
if len(pullErrs) > 0 {
err = utilerrors.NewAggregate(pullErrs)

Check warning on line 99 in pkg/daemon/criruntime/imageruntime/pouch.go

View check run for this annotation

Codecov / codecov/patch

pkg/daemon/criruntime/imageruntime/pouch.go#L98-L99

Added lines #L98 - L99 were not covered by tests
}
} else {
klog.Errorf("Failed to convert to auth info for registry, err %v", err)

Check warning on line 102 in pkg/daemon/criruntime/imageruntime/pouch.go

View check run for this annotation

Codecov / codecov/patch

pkg/daemon/criruntime/imageruntime/pouch.go#L101-L102

Added lines #L101 - L102 were not covered by tests
}

// Try the default secret
Expand Down

0 comments on commit 2f77a4d

Please sign in to comment.