0
0
Dockerdevops~10 mins

Pushing images to registry in Docker - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the command to push a Docker image named myapp to the default registry.

Docker
docker push [1]
Drag options to blanks, or click blank then click option'
Aimage myapp
Bmyapp
Cdocker myapp
Dpush myapp
Attempts:
3 left
💡 Hint
Common Mistakes
Including extra words like 'push' or 'image' after the command.
Using 'docker myapp' which is not a valid command.
2fill in blank
medium

Complete the command to tag a local image myapp with the registry URL registry.example.com/myapp.

Docker
docker tag myapp [1]
Drag options to blanks, or click blank then click option'
Aregistry.example.com/myapp
Bmyapp:latest
Cregistry/myapp
Dexample.com/myapp
Attempts:
3 left
💡 Hint
Common Mistakes
Using only the image name without the registry URL.
Using incomplete or incorrect registry URLs.
3fill in blank
hard

Fix the error in the command to push the image registry.example.com/myapp to the registry.

Docker
docker [1] registry.example.com/myapp
Drag options to blanks, or click blank then click option'
Abuild
Btag
Cpull
Dpush
Attempts:
3 left
💡 Hint
Common Mistakes
Using pull instead of push.
Using tag which only renames images locally.
4fill in blank
hard

Complete the command to push the myapp image to registry.example.com/user/myapp:latest.

Docker
docker push registry.example.com[1]myapp[2]
Drag options to blanks, or click blank then click option'
A/user/
B:latest
C/admin/
D@sha256:abc123
Attempts:
3 left
💡 Hint
Common Mistakes
Omitting the namespace path.
Forgetting to specify the image tag.
5fill in blank
hard

Fill all three blanks to build and push the Docker image with the 'latest' tag to the registry.

Docker
docker build -t registry.example.com/myapp[1] . && docker [2] registry.example.com/myapp[3]
Drag options to blanks, or click blank then click option'
A:latest
Bpush
Crun
D:v1.0
Attempts:
3 left
💡 Hint
Common Mistakes
Using run or build instead of push.
Using a different tag like :v1.0 instead of :latest.
Omitting the tag in one of the commands.