<p>Trying to pull jenkins image using <strong>helm install stable/jenkins --values jenkins.values --name jenkins</strong>
to into my local cluster,but every time, when i do build pod its gives the error as following.</p>

<p>`</p>

<pre><code>[root@kube-master tmp]# kubectl describe pod newjenkins-84cd855fb6-mr9rm
Name:           newjenkins-84cd855fb6-mr9rm
Namespace:      default
Priority:       0
Node:           worker-node2/192.168.20.56
Start Time:     Thu, 14 May 2020 14:58:13 +0500
Labels:         app.kubernetes.io/component=jenkins-master
                app.kubernetes.io/instance=newjenkins
                app.kubernetes.io/managed-by=Tiller
                app.kubernetes.io/name=jenkins
                helm.sh/chart=jenkins-1.16.0
                pod-template-hash=84cd855fb6
Annotations:    checksum/config: 70d4b49bc5cd79a1a978e1bbafdb8126f8accc44871772348fd481642e33cffb
Status:         Pending
IP:
IPs:            &lt;none&gt;
Controlled By:  ReplicaSet/newjenkins-84cd855fb6
Init Containers:
  copy-default-config:
    Container ID:
    Image:         jenkins/jenkins:lts
    Image ID:
    Port:          &lt;none&gt;
    Host Port:     &lt;none&gt;
    Command:
      sh
      /var/jenkins_config/apply_config.sh
    State:          Waiting
      Reason:       PodInitializing
    Ready:          False
    Restart Count:  0
    Limits:
      cpu:     2
      memory:  4Gi
    Requests:
      cpu:     50m
      memory:  256Mi
    Environment:
      ADMIN_PASSWORD:  &lt;set to the key 'jenkins-admin-password' in secret 'newjenkins'&gt;  Optional: false
      ADMIN_USER:      &lt;set to the key 'jenkins-admin-user' in secret 'newjenkins'&gt;      Optional: false
    Mounts:
      /tmp from tmp (rw)
      /usr/share/jenkins/ref/secrets/ from secrets-dir (rw)
      /var/jenkins_config from jenkins-config (rw)
      /var/jenkins_home from jenkins-home (rw)
      /var/jenkins_plugins from plugin-dir (rw)
      /var/run/secrets/kubernetes.io/serviceaccount from newjenkins-token-jmfsz (ro)
Containers:
  jenkins:
    Container ID:
    Image:         jenkins/jenkins:lts
    Image ID:
    Ports:         8080/TCP, 50000/TCP
    Host Ports:    0/TCP, 0/TCP
    Args:
      --argumentsRealm.passwd.$(ADMIN_USER)=$(ADMIN_PASSWORD)
      --argumentsRealm.roles.$(ADMIN_USER)=admin
      --httpPort=8080
    State:          Waiting
      Reason:       PodInitializing
    Ready:          False
    Restart Count:  0
    Limits:
      cpu:     2
      memory:  4Gi
    Requests:
      cpu:      50m
      memory:   256Mi
    Liveness:   http-get http://:http/login delay=90s timeout=5s period=10s #success=1 #failure=5
    Readiness:  http-get http://:http/login delay=60s timeout=5s period=10s #success=1 #failure=3
    Environment:
      POD_NAME:                  newjenkins-84cd855fb6-mr9rm (v1:metadata.name)
      JAVA_OPTS:
      JENKINS_OPTS:
      JENKINS_SLAVE_AGENT_PORT:  50000
      ADMIN_PASSWORD:            &lt;set to the key 'jenkins-admin-password' in secret 'newjenkins'&gt;  Optional: false
      ADMIN_USER:                &lt;set to the key 'jenkins-admin-user' in secret 'newjenkins'&gt;      Optional: false
    Mounts:
      /tmp from tmp (rw)
      /usr/share/jenkins/ref/plugins/ from plugin-dir (rw)
      /usr/share/jenkins/ref/secrets/ from secrets-dir (rw)
      /var/jenkins_config from jenkins-config (ro)
      /var/jenkins_home from jenkins-home (rw)
      /var/run/secrets/kubernetes.io/serviceaccount from newjenkins-token-jmfsz (ro)
Conditions:
  Type              Status
  Initialized       False
  Ready             False
  ContainersReady   False
  PodScheduled      True
Volumes:
  plugins:
    Type:       EmptyDir (a temporary directory that shares a pod's lifetime)
    Medium:
    SizeLimit:  &lt;unset&gt;
  tmp:
    Type:       EmptyDir (a temporary directory that shares a pod's lifetime)
    Medium:
    SizeLimit:  &lt;unset&gt;
  jenkins-config:
    Type:      ConfigMap (a volume populated by a ConfigMap)
    Name:      newjenkins
    Optional:  false
  secrets-dir:
    Type:       EmptyDir (a temporary directory that shares a pod's lifetime)
    Medium:
    SizeLimit:  &lt;unset&gt;
  plugin-dir:
    Type:       EmptyDir (a temporary directory that shares a pod's lifetime)
    Medium:
    SizeLimit:  &lt;unset&gt;
  jenkins-home:
    Type:       PersistentVolumeClaim (a reference to a PersistentVolumeClaim in the same namespace)
    ClaimName:  newjenkins
    ReadOnly:   false
  newjenkins-token-jmfsz:
    Type:        Secret (a volume populated by a Secret)
    SecretName:  newjenkins-token-jmfsz
    Optional:    false
QoS Class:       Burstable
Node-Selectors:  &lt;none&gt;
Tolerations:     node.kubernetes.io/not-ready:NoExecute for 300s
                 node.kubernetes.io/unreachable:NoExecute for 300s
Events:
  Type    Reason     Age        From                   Message
  ----    ------     ----       ----                   -------
  Normal  Scheduled  &lt;unknown&gt;  default-scheduler      Successfully assigned default/newjenkins-84cd855fb6-mr9rm to worker-node2
  Normal  Pulling    9m41s      kubelet, worker-node2  Pulling image "jenkins/jenkins:lts"
[root@kube-master tmp]# kubectl describe pod newjenkins-84cd855fb6-mr9rm
Name:           newjenkins-84cd855fb6-mr9rm
Namespace:      default
Priority:       0
Node:           worker-node2/192.168.20.56
Start Time:     Thu, 14 May 2020 14:58:13 +0500
Labels:         app.kubernetes.io/component=jenkins-master
                app.kubernetes.io/instance=newjenkins
                app.kubernetes.io/managed-by=Tiller
                app.kubernetes.io/name=jenkins
                helm.sh/chart=jenkins-1.16.0
                pod-template-hash=84cd855fb6
Annotations:    checksum/config: 70d4b49bc5cd79a1a978e1bbafdb8126f8accc44871772348fd481642e33cffb
Status:         Pending
IP:
IPs:            &lt;none&gt;
Controlled By:  ReplicaSet/newjenkins-84cd855fb6
Init Containers:
  copy-default-config:
    Container ID:
    Image:         jenkins/jenkins:lts
    Image ID:
    Port:          &lt;none&gt;
    Host Port:     &lt;none&gt;
    Command:
      sh
      /var/jenkins_config/apply_config.sh
    State:          Waiting
      Reason:       ErrImagePull
    Ready:          False
    Restart Count:  0
    Limits:
      cpu:     2
      memory:  4Gi
    Requests:
      cpu:     50m
      memory:  256Mi
    Environment:
      ADMIN_PASSWORD:  &lt;set to the key 'jenkins-admin-password' in secret 'newjenkins'&gt;  Optional: false
      ADMIN_USER:      &lt;set to the key 'jenkins-admin-user' in secret 'newjenkins'&gt;      Optional: false
    Mounts:
      /tmp from tmp (rw)
      /usr/share/jenkins/ref/secrets/ from secrets-dir (rw)
      /var/jenkins_config from jenkins-config (rw)
      /var/jenkins_home from jenkins-home (rw)
      /var/jenkins_plugins from plugin-dir (rw)
      /var/run/secrets/kubernetes.io/serviceaccount from newjenkins-token-jmfsz (ro)
Containers:
  jenkins:
    Container ID:
    Image:         jenkins/jenkins:lts
    Image ID:
    Ports:         8080/TCP, 50000/TCP
    Host Ports:    0/TCP, 0/TCP
    Args:
      --argumentsRealm.passwd.$(ADMIN_USER)=$(ADMIN_PASSWORD)
      --argumentsRealm.roles.$(ADMIN_USER)=admin
      --httpPort=8080
    State:          Waiting
      Reason:       PodInitializing
    Ready:          False
    Restart Count:  0
    Limits:
      cpu:     2
      memory:  4Gi
    Requests:
      cpu:      50m
      memory:   256Mi
    Liveness:   http-get http://:http/login delay=90s timeout=5s period=10s #success=1 #failure=5
    Readiness:  http-get http://:http/login delay=60s timeout=5s period=10s #success=1 #failure=3
    Environment:
      POD_NAME:                  newjenkins-84cd855fb6-mr9rm (v1:metadata.name)
      JAVA_OPTS:
      JENKINS_OPTS:
      JENKINS_SLAVE_AGENT_PORT:  50000
      ADMIN_PASSWORD:            &lt;set to the key 'jenkins-admin-password' in secret 'newjenkins'&gt;  Optional: false
      ADMIN_USER:                &lt;set to the key 'jenkins-admin-user' in secret 'newjenkins'&gt;      Optional: false
    Mounts:
      /tmp from tmp (rw)
      /usr/share/jenkins/ref/plugins/ from plugin-dir (rw)
      /usr/share/jenkins/ref/secrets/ from secrets-dir (rw)
      /var/jenkins_config from jenkins-config (ro)
      /var/jenkins_home from jenkins-home (rw)
      /var/run/secrets/kubernetes.io/serviceaccount from newjenkins-token-jmfsz (ro)
Conditions:
  Type              Status
  Initialized       False
  Ready             False
  ContainersReady   False
  PodScheduled      True
Volumes:
  plugins:
    Type:       EmptyDir (a temporary directory that shares a pod's lifetime)
    Medium:
    SizeLimit:  &lt;unset&gt;
  tmp:
    Type:       EmptyDir (a temporary directory that shares a pod's lifetime)
    Medium:
    SizeLimit:  &lt;unset&gt;
  jenkins-config:
    Type:      ConfigMap (a volume populated by a ConfigMap)
    Name:      newjenkins
    Optional:  false
  secrets-dir:
    Type:       EmptyDir (a temporary directory that shares a pod's lifetime)
    Medium:
    SizeLimit:  &lt;unset&gt;
  plugin-dir:
    Type:       EmptyDir (a temporary directory that shares a pod's lifetime)
    Medium:
    SizeLimit:  &lt;unset&gt;
  jenkins-home:
    Type:       PersistentVolumeClaim (a reference to a PersistentVolumeClaim in the same namespace)
    ClaimName:  newjenkins
    ReadOnly:   false
  newjenkins-token-jmfsz:
    Type:        Secret (a volume populated by a Secret)
    SecretName:  newjenkins-token-jmfsz
    Optional:    false
QoS Class:       Burstable
Node-Selectors:  &lt;none&gt;
Tolerations:     node.kubernetes.io/not-ready:NoExecute for 300s
                 node.kubernetes.io/unreachable:NoExecute for 300s
Events:
  Type     Reason          Age                From                   Message
  ----     ------          ----               ----                   -------
  Normal   Scheduled       &lt;unknown&gt;          default-scheduler      Successfully assigned default/newjenkins-84cd855fb6-mr9rm to worker-node2
  Warning  Failed          50s                kubelet, worker-node2  Failed to pull image "jenkins/jenkins:lts": rpc error: code = Unknown desc = unauthorized: authentication required
  Warning  Failed          50s                kubelet, worker-node2  Error: ErrImagePull
  Normal   SandboxChanged  49s                kubelet, worker-node2  Pod sandbox changed, it will be killed and re-created.
  Normal   Pulling 28s (x2 over 10m)  kubelet, worker-node2  Pulling image "jenkins/jenkins:lts"
</code></pre>

<p>Pull the jenkins image manually using docker pull jenkins with docker hub login and without  docker hub account login, every time Give me error ErrImagePull.</p>

<p>The hint is in the <code>Events</code> section:</p>

<pre><code>Failed to pull image "jenkins/jenkins:lts": rpc error: code = Unknown desc = unauthorized: authentication required
</code></pre>

<p>The kubelet on worker nodes performs a <code>docker pull</code> prior to executing the pod when it spins up the containers.</p>

<p>Make sure the node is logged in with <code>docker login</code> so the local worker nodes can pull the image manually, if you haven't already.</p>

<p>If you have and it's still happening, you may need a secret in place to access the repository in question.  If it's still happening even then, don't use a short name for your image (not <code>jenkins/jenkins:lts</code>, specify the full path, like <code>my-image-registry:5001/jenkins/jenkins:lts</code>) to ensure it's pulling from the right place and not the default registries Docker is configured with.  Hope that helps.</p>
