Unable to find docker image locally
Solution 1
Well this is anti-logical but still sharing so future people like me don't get stuck
So the problem was that I was trying to run a docker image which doesn't exist.
I needed to build the image:
docker build . -t xameeramir/cra-docker
And then run it:
docker run -p 8080:80 xameeramir/cra-docker
Solution 2
In my case, my image had TAG specified with it and I was not using it.
REPOSITORY TAG IMAGE ID CREATED SIZE
testimage testtag 189b7354c60a 13 hours ago 88.3MB
Unable to find image 'testimage:latest' locally
for this command docker run testimage
So specifying tag like this - docker run testimage:testtag
worked for me
Solution 3
I received this error message when I typed the name/character wrong. That is, "name1\name2" instead of "name1/name2" (wrong slash).
Solution 4
In my case, the docker image did exist on the system and still I couldn't run the container locally, so I used the exact image ID instead of image name and tag, like this:
docker run myContainer c29150c8588e
Solution 5
In my case, I saw this error when I had logged in to the dockerhub in my docker desktop. The repo I was pulling was local to my enterprise. Once i logged out of dockerhub, the pull worked.
Zameer Ansari
Updated on July 05, 2022Comments
-
Zameer Ansari almost 2 years
I was following this post - the reference code is on GitHub. I have cloned the repository on my local.
The project has got a react app inside it. I'm trying to run it on my local following step 7 on the same post:
docker run -p 8080:80 shakyshane/cra-docker
This returns:
Unable to find image 'shakyshane/cra-docker:latest' locally docker: Error response from daemon: pull access denied for shakyshane/cra-docker, repository does not exist or may require 'docker login'. See 'docker run --help'.
I tried login to docker again but looks like since it belongs to @shakyShane I cannot access it.
I idiotically tried
npm start
too but it's not a simple react app running on node - it's in the container and containers are not controlled bynpm
Looks like
docker pull shakyshane/cra-docker:latest
throws this:Error response from daemon: pull access denied for shakyshane/cra-docker, repository does not exist or may require 'docker login'
So the question is how do I run this docker image on my local mac machine?
-
Zameer Ansari about 5 yearsAgree @RichardBarber it was a mistake of mine. Thanks anyways for your help :)
-
Sownak Roy about 4 yearsHey, I think this is not the right answer. The docker image is not public and so this user cannot download the image.
-
Tomk07 about 3 yearsHi (docker newb here), excuse my ignorance please. How did you print that top line of your comment, with the repo details??
-
Seba99 about 3 yearsIt's
docker image list
-
mbuechmann over 2 yearsThis does not provide an answer to the question. To critique or request clarification from an author, leave a comment below their post. - From Review