GoogleContainerTools / GoogleContainerTools/skaffold

Bug: Issue with imagePullPolicy on a deployment

Open
#9,872 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Go
Stars
15.9k
Forks
1.7k
Avg merge
3d 9h
Merged PRs (30d)
10

Description

Hello,
I encountered a weird issue with a deployment manifest that is using a local image
```
Waiting for deployments to stabilize...
- deployment/ is ready. [2/3 deployment(s) still pending]
- deployment/: container 1 is waiting to start: :5b0737433ed8db461f77b1cd1f1247b656be55455ad43b64553d149d4bafa0b8 can't be pulled
- pod/: container 2 is waiting to start: :5b0737433ed8db461f77b1cd1f1247b656be55455ad43b64553d149d4bafa0b8 can't be pulled
- deployment/ failed. Error: container 1 is waiting to start: :5b0737433ed8db461f77b1cd1f1247b656be55455ad43b64553d149d4bafa0b8 can't be pulled.
1/3 deployment(s) failed
```
```
Warning Failed 2m22s (x3 over 3m) kubelet Error: ErrImagePull
Normal Pulling 2m22s (x3 over 3m) kubelet Pulling image ":b037a3e41ede9affbec1db26eef4df772cdff1446779aaf3fa056da188dd08b4"
Warning Failed 2m21s (x3 over 3m) kubelet Failed to pull image ":b037a3e41ede9affbec1db26eef4df772cdff1446779aaf3fa056da188dd08b4": failed to pull and unpack image "docker.io/library/:b037a3e41ede9affbec1db26eef4df772cdff1446779aaf3fa056da188dd08b4": failed to resolve reference "docker.io/library/:b037a3e41ede9affbec1db26eef4df772cdff1446779aaf3fa056da188dd08b4": pull access denied, repository does not exist or may require authorization: server message: insufficient_scope: authorization failed
```

This is the deployment that was causing the issue :
```
apiVersion: apps/v1
kind: Deployment
metadata:
name:
spec:
replicas: 1
selector:
matchLabels:
app:
template:
metadata:
labels:
app:
spec:
containers:
- name: 1
image:
imagePullPolicy: Always
ports:
- containerPort: 80
...
```

When i remove the imagePullPolicy, its working, I stumbled upon this https://github.com/GoogleContainerTools/skaffold/pull/9495, so i assume this issue should not be happening

```
> skaffold version
v2.16.1
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.