skip to Main Content

I need pull a docker image of tensorflow.

I know that for pull a image i have to use this commmand:

docker pull tensorflow/tensorflow:2.4.3

But i dont want my image with this name:

tensorflow/tensorflow:2.4.3

How can i change this name in the moment that i pull it ?

2

Answers


  1. The location you pulled it from and the name are tightly coupled. So you can retag after pulling:

    docker pull tensorflow/tensorflow:2.4.3
    docker tag tensorflow/tensorflow:2.4.3 yourid/tensorflow:2.4.3
    

    Otherwise, you’d need to pull the image from outside of docker and side load the image, but that’s really more effort than it’s worth, and losses efficiencies like skipping already pulled layers.

    Login or Signup to reply.
  2. you could also do:

    docker pull -q tensorflow/tensorflow:2.4.3 | xargs -I{} docker tag {} yourid/tensorflow:2.4.3
    
    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search