Cloud and Container Basics

An image is pulled by specifying registry.example.com/team/web:1.4. Which of the following correctly gives the meaning of each part of this reference?

  1. Aregistry.example.com: repository; team/web: tag; 1.4: digest computed from the image contents
  2. Bregistry.example.com: registry (the server that stores images); team/web: repository; 1.4: tag
  3. Cregistry.example.com: registry; team: repository; web: tag; 1.4: name of the container to start
Show answer and explanation

Answer: B. registry.example.com: registry (the server that stores images); team/web: repository; 1.4: tag

An image reference has the form "registry/repository:tag": the registry is the server that stores and distributes images, the repository groups images of the same kind, and the tag is a name for a version or the like; in this example, registry.example.com is the registry, team/web the repository and 1.4 the tag. If the registry is omitted, the default registry (Docker Hub) is used, and if the tag is omitted, latest is used. A tag is a name given by users, and the same tag can later be moved to a different image. The identifier that always changes when the contents change is the digest beginning with sha256, which is specified after @.

  • A. 1.4 is a tag given by users. A digest is specified in the form "@sha256:…".
  • B. Correct. The registry, repository and tag appear in that order.
  • C. The whole of team/web is the repository name, and 1.4 is the tag. A container name is given at docker run.
Practice this topic Back to topic

Books on Cloud and Container Basics Ad

As an Amazon Associate I earn from qualifying purchases.

More Cloud and Container Basics questions

  1. scratch is an empty image that contains no files. Which of the following correctly describes what the final image built with the multi-stage Dockerfile above contains?
  2. In Kubernetes, which of the following is the smallest unit that is deployed and managed, grouping one or more containers that share the same IP address and volumes?
  3. In Kubernetes, a Deployment with replicas: 3 is running three Pods. Which of the following correctly describes what happens when one of these Pods is deleted with kubectl delete pod?
  4. In a Kubernetes Deployment, the container image in the Pod template is changed to a new version. Which of the following correctly describes what happens with the default update strategy (RollingUpdate)?
  5. A Deployment with replicas: 10 has the rolling update settings maxSurge: 25% and maxUnavailable: 25%. Which of the following correctly gives the upper limit of the total number of Pods and the lower limit of the number of available Pods during an update?