Kuberentes: pulling image from private repo

0 votes

I have set up my clsuter using kubeadm(alpha). I am trying to pull a docker image I've hosted in nexus repo. But it gives ImagePullBackOff error whenever I try and launch a pod with this repo. Am I doing something wrong?

Here's the Pod definition :

apiVersion: v1
kind: Pod
  name: test-pod
    name: test
    - image: 123.456.789.0:9595/test
      name: test
        - containerPort: 8443
    - name: my-secret
Jan 11 in Kubernetes by Atul
• 5,470 points

1 answer to this question.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
0 votes

You'll have to refer to the secret that you mentioned inside the pod definition.

If your're creating a secret with kubectl create secret docker-registry my-secret --docker-server=123.456.789.0... it should match exactly to what you're putting in your pod definition including the port number and in case it is secured then it be the same as the one in docker command line in systemd.

One more thing you need to make sure is that the secret and your pod should be in the same namespace otherwise they won't be able to communicate.

answered Jan 11 by ajs3033
• 7,000 points

Related Questions In Kubernetes

0 votes
1 answer

Not able to pull image from gcr.io

There was a recent outage to gce ...READ MORE

answered Aug 28, 2018 in Kubernetes by Kalgi
• 35,750 points
0 votes
1 answer

Accessing private Docker Hub repository from Kubernetes on Vagrant

In order to pull private dockerhub hosted ...READ MORE

answered Sep 18, 2018 in Kubernetes by DareDev
• 6,520 points
0 votes
1 answer

How can I access a service installed on Kubernetes from anywhere?

I have followed the link which you have ...READ MORE

answered Jul 23, 2018 in Kubernetes by Atul
• 10,190 points
+2 votes
3 answers

local docker image on minikube

Try something like this: # Start minikube minikube start # ...READ MORE

answered Aug 29, 2018 in Kubernetes by Nilesh
• 6,900 points
0 votes
1 answer
0 votes
1 answer
0 votes
1 answer

Re-pulling image in kubernetes

There are only two scenarios when kubernetes ...READ MORE

answered Jan 9 in Kubernetes by ajs3033
• 7,000 points
0 votes
2 answers

© 2018 Brain4ce Education Solutions Pvt. Ltd. All rights Reserved.
"PMP®","PMI®", "PMI-ACP®" and "PMBOK®" are registered marks of the Project Management Institute, Inc. MongoDB®, Mongo and the leaf logo are the registered trademarks of MongoDB, Inc.