What is the meaning of ImagePullBackOff status on a Kubernetes pod?

前端 未结 9 1474
梦毁少年i
梦毁少年i 2021-02-02 04:49

I\'m trying to run my first kubernetes pod locally. I\'ve run the following command (from here):

export ARCH=amd64
docker run -d \\
    --volume=/:/rootfs:ro \\
         


        
9条回答
  •  失恋的感觉
    2021-02-02 05:36

    By default Kubernetes looks in the public Docker registry to find images. If your image doesn't exist there it won't be able to pull it.

    You can run a local Kubernetes registry with the registry cluster addon.

    Then tag your images with localhost:5000:

    docker tag aii localhost:5000/dev/aii
    

    Push the image to the Kubernetes registry:

    docker push localhost:5000/dev/aii
    

    And change run-aii.yaml to use the localhost:5000/dev/aii image instead of aii. Now Kubernetes should be able to pull the image.

    Alternatively, you can run a private Docker registry through one of the providers that offers this (AWS ECR, GCR, etc.), but if this is for local development it will be quicker and easier to get setup with a local Kubernetes Docker registry.

提交回复
热议问题