Which of the following will display the specific command that created each layer in an image?
- docker search imagename
- docker images -t imagename
- docker history imagename (Ans)
- docker build -th imagename
You would prepare an image called hello-world for uploading to a local Docker Registry using which of the following commands?
- docker tag hello-world localhost/hello-world:latest
- docker -tag 127.0.0.1/hello-world:latest
- docker -t hello-world localhost:5000/hello-world:latest
- docker tag hello-world localhost:5000/hello-world:latest (Ans)
Where are the image files stored on a Linux machine running a package-based Docker Registry?
- /var/lib/docker/docker-registry/docker/registry/v2/repositories (Ans)
- /var/lib/docker/docker-registry/docker/registry/v2/_catalog
- /var/lib/docker/volumes//_data/docker/registry/v2/repositories/
- /var/lib/docker/docker-registry
Which of these commands will return a list of images currently stored in a Docker Registry?
- curl 192.168.1.17:5000/v2/_data
- curl 192.168.1.17:5000/v2/_catalog (Ans)
- docker images
- docker registry ls
To add encryption using a self-signed certificate to your Docker Registry infrastructure, to which directory must the certificate be copied (assuming your domain is domain.com)?
- /etc/docker/cert.d/domain.com:5000/
- /var/lib/docker/certs.d/domain.com:5000/
- /etc/docker/certs.d/domain.com:5000/ (Ans)
- /etc/docker/certs.d/domain.com/
How do you temporarily enable Docker Content Trust on your local machine to take advantage of digitally signed images?
- export $DOCKER_CONTENT_TRUST=0
- export DOCKER_CONTENT_TRUST=1 (Ans)
- echo $DOCKER_CONTENT_TRUST=1
- echo DOCKER_CONTENT_TRUST=1 >> /etc/profile
Which of the following will upload a new stack to your Docker Cloud account?
- docker-cloud stack create -f dockerfile
- docker-cloud stack create docker-cloud.yml
- docker stack create -f docker-cloud.yml
- docker-cloud stack create -f docker-cloud.yml (Ans)
Docker Engine is:
- An online Docker image repository
- An online Docker administration interface
- The locally installed runtime through which you administrate Docker containers (Ans)
- A local Docker image repository
Docker Trusted Registry is:
- An open source tool for securing the infrastructure on which Docker Engine runs
- An open source tool for coordinating Docker container clusters
- A web-based, commercial, hosted image management tool (Ans)
- A local, commercial image management tool
A Docker container will run faster when its image is properly optimized. Which of the following will have the greatest positive impact on speed?
- Build the image using as few layers as possible. (Ans)
- Always base your images on the latest operating system version available.
- Build the image using a Dockerfile rather than from a running container.
- Always be consistent in the software package versions you choose for your image layers
Which of the following commands will successfully build an image with the name “myimage”?
- docker build -t myimage . (Ans)
- docker build –tag-image myimage
- docker build -t myimage
- docker build -n myimage .
What is accomplished by running the following command?
docker run -p 5000:5000 registry:latest
- Only if the Docker Registry image has already been pulled will it be run, exposing port 5000.
- The Docker Registry image will (if necessary) be pulled and then run, exposing port 5000. (Ans)
- Docker Engine will run a “hot update” on the live Registry image.
- The Docker Registry image will be pulled from Docker Hub using port 5000.
Which of these is the correct command to display a list images currently stored in a Docker Registry using a self-signed certificate?
- curl -i https://192.168.1.16:5000/v2/_data
- curl -i https://192.168.1.16:5000/v2/_catalog
- curl –insecure http://192.168.1.16:5000/v2/_catalog
- curl –insecure https://192.168.1.16:5000/v2/_catalog (Ans)
I’m Rajesh Kumar, a DevOps, SRE, DevSecOps, Cloud, and Platform Engineering expert passionate about sharing practical knowledge, real-world experiences, and industry best practices. I have worked at Cotocus and regularly write about technology, travel, investing, health, product reviews, and digital marketing through my various platforms.
I publish technical articles at DevOps School, travel stories at Holiday Landmark, stock market insights at Stocks Mantra, health and fitness guidance at My Medic Plus, product reviews at TrueReviewNow, and SEO and digital marketing strategies at Wizbrand.
Find Trusted Cardiac Hospitals
Compare heart hospitals by city and services — all in one place.
Explore Hospitals