🚀 DevOps & SRE Certification Program 📅 Starting: 1st of Every Month 🤝 +91 8409492687 🔍 Contact@DevOpsSchool.com

Upgrade & Secure Your Future with DevOps, SRE, DevSecOps, MLOps!

We spend hours on Instagram and YouTube and waste money on coffee and fast food, but won’t spend 30 minutes a day learning skills to boost our careers.
Master in DevOps, SRE, DevSecOps & MLOps!

Learn from Guru Rajesh Kumar and double your salary in just one year.


Get Started Now!

Docker Interview Questions and Answer Part – 21

Which of the following is needed to deploy a Docker Stack?

  • Compose v2 file format
  • Kubernetes
  • Compose v3 file format
  • Docker Cloud (Ans)

What is the name of the configuration file that describes how to build a new Docker image with your app-code inside?

  • dockerfile (Ans)
  • config.json
  • docker-file
  • dockerfile.json

Which of the following is the worst number of managers for high availability?

  • 1
  • 5
  • 2 (Ans)
  • 7

Which command can you use to get a shell session inside of a container?

  • docker container login
  • docker container exec (Ans)
  • docker container shell
  • docker container ssh

Which Docker EE technology performs layer-7 (application layer) load balancing?

  • The ingress network
  • The Service Mesh
  • The HTTP Routing Mesh (HRM) (Ans)

Which of the following best decribes a Docker Image?

  • A read-write template for starting one or more containers
  • A point-in-time snapshot of a container used for backups
  • A data volume that can be mounted inside of a container
  • A read-only template for starting one or more containers (Ans)

You have two services running on a Swarm, but they cannot find each other by name. Which of the following could be the reason why?

  • They are on different overlay networks (Ans)
  • They were not manually registered with the Swarm DNS when they were created
  • Service discovery only works on bridge/NAT networks
  • You did not create the Swarm DNS

Which of the following is a loose definition of a Docker container?

  • A VM running a shared kernel with resource limits applied
  • A unikernel running on a hypervisor with resource limits applied
  • An isolated area of an Operating System with resource limits applied (Ans)

What will happen if you start a new container or service and specify a volume that does not currently exist?

  • You will be prompted to create the new volume
  • The command will complete but the container/service will fail to start
  • The command will fail
  • Docker will create the volume for you (Ans)

What are the base requirements to be able to use Docker Secrets?

  • Swarm mode and an external CA
  • Swarm mode and self-encrypting disks for the cluster store
  • Docker in Swarm mode (Ans)
  • Docker

Which of the following are top-level keys in a stack file (Compose v3 file)?

  • Version, deployments, networks, volumes
  • Version and services
  • Version, services, networks, volumes (Ans)
  • Services, pods, networks, volumes

Which of the following is an advantage of Multi-stage Builds?

  • Multi-platform images
  • Better image documentation
  • Faster image builds
  • Smaller images (Ans)

Which of the following is a recommended number of Swarm managers for high availability?

  • 4
  • 3 (Ans)
  • 2

Which of the following best describes a Bridge (NAT on Windows) network in Docker?

  • Token-ring (Ans)
  • Multi-host overlay network
  • A single-host network

How does the HRM know how to route traffic to the correct service?

  • iptables rules
  • It inspects HTTP host headers (Ans)
  • DNS labels
  • Custom load balancer rules

By default, where are Docker daemon logs sent to on a Linux system running systemd?

  • syslog
  • The Linux event viewer
  • journald (Ans)

Which of the following is a major goal of Docker volumes?

  • Data replication
  • Data encryption at-rest
  • Object storage
  • Persistent data (Ans)
  • RAID

Which are the two major kernel building blocks that containers are built from?

  • Capabilities and seccomp
  • Namespaces and kernels
  • Namespaces and control groups (Ans)
  • Capabilities and control groups

Certification Courses

DevOpsSchool has introduced a series of professional certification courses designed to enhance your skills and expertise in cutting-edge technologies and methodologies. Whether you are aiming to excel in development, security, or operations, these certifications provide a comprehensive learning experience. Explore the following programs:

DevOps Certification, SRE Certification, and DevSecOps Certification by DevOpsSchool

Explore our DevOps Certification, SRE Certification, and DevSecOps Certification programs at DevOpsSchool. Gain the expertise needed to excel in your career with hands-on training and globally recognized certifications.