pull access denied repository does not exist or may require docker login

前端 未结 16 1922
悲哀的现实
悲哀的现实 2021-02-02 05:18

I am using Laravel 4.2 with docker. I setup it on local. It worked without any problem but when I am trying to setup online using same procedure then I am getting error

相关标签:
16条回答
  • 2021-02-02 05:28

    I solved this by inserting a language at the front of the docker image

    FROM python:3.7-alpine

    0 讨论(0)
  • 2021-02-02 05:28

    If you're downloading from somewhere else than your own registry or docker-hub, you might have to do a separate agreement of terms on their site, like the case with Oracle's docker registry. It allows you to do docker login fine, but pulling the container won't still work until you go to their site and agree on their terms.

    0 讨论(0)
  • 2021-02-02 05:29

    Please note that the error message from Docker is misleading.

    $ docker build deploy/.
    Sending build context to Docker daemon  5.632kB
    Step 1/16 : FROM rhel7:latest
    pull access denied for rhel7, repository does not exist or may require 'docker login'
    

    It says that it may require 'docker login'. I struggled with this. I realized the image does not exist at https://hub.docker.com any more. I hope this helps someone.

    0 讨论(0)
  • 2021-02-02 05:29

    If the repository is private you have to assign permissions to download it. You have two options, with the docker login command, or put in ~/.docker/docker.config the file generated once you login.

    0 讨论(0)
  • 2021-02-02 05:30

    I had this because I inadvertantly remove the AS tag from my first image:

    ex:

    FROM mcr.microsoft.com/windows/servercore:1607-KB4546850-amd64
    ...
    .. etc ...
    ...
    FROM mcr.microsoft.com/windows/servercore:1607-KB4546850-amd64
    COPY --from=installer ["/dotnet", "/Program Files/dotnet"]
    ... etc ...
    

    should have been:

    FROM mcr.microsoft.com/windows/servercore:1607-KB4546850-amd64 AS installer
    ...
    .. etc ...
    ...
    FROM mcr.microsoft.com/windows/servercore:1607-KB4546850-amd64
    COPY --from=installer ["/dotnet", "/Program Files/dotnet"]
    ... etc ...
    
    0 讨论(0)
  • 2021-02-02 05:31

    If you don't have an image with that name locally, docker will try to pull it from docker hub, but there's no such image on docker hub. Or simply try "docker login".

    0 讨论(0)
提交回复
热议问题