title: Kubernetes cannot pull image from private docker image repository
body: <p>I have problem with kubernetes (minikube) and pull images from local image repository on docker.
  Docker repository was created:</p>
  
  <pre><code>docker run --entrypoint htpasswd registry:2 -Bbn zordon examplePassword &gt; /mnt/LINUX/auth/htpasswd
  
  docker run -d \
    -p 5000:5000 \
    --restart=always \
    --name registry \
    -v /mnt/LINUX/dockerreg:/var/lib/registry \
    -v /mnt/LINUX/auth:/auth \
    -e "REGISTRY_AUTH=htpasswd" \
    -e "REGISTRY_AUTH_HTPASSWD_REALM=Registry Realm" \
    -e REGISTRY_AUTH_HTPASSWD_PATH=/auth/htpasswd \
    registry:2
  </code></pre>
  
  <p>Then I want to create simple pod with image which was succesfully uploaded to local repository:</p>
  
  <pre><code>curl localhost:5000/v2/_catalog
  {"repositories":["car/configuration"]}
  </code></pre>
  
  <p>I have also create secret on minikube cluster with:</p>
  
  <pre><code>kubectl create secret docker-registry docregkey --docker-server=localhost:5000 --docker-username=zordon --docker-password=examplePassword --docker-email=test@dock.mail
  </code></pre>
  
  <p>and define simple Pod:</p>
  
  <pre><code>    apiVersion: v1
  kind: Pod
  metadata:
    name: private-reg
  spec:
    containers:
    - name: private-reg-container
      image: car/configuration:latest
      imagePullPolicy: Always
    restartPolicy: Always
    imagePullSecrets:
    - name: docregkey
  </code></pre>
  
  <p>unfortunatelly I getting still:</p>
  
  <blockquote>
    <p>Failed to pull image "car/configuration:latest": rpc error: code =
    Unknown desc = Error response from daemon: pull access denied for
    car/configuration, repository does not exist or may require 'docker
    login'</p>
  </blockquote>
  
  <p>How i can fix this problem ?</p>