What is the primary way to define and deploy applications in a Docker Swarm?
Docker Swarm stacks
Dockerfiles
Kubernetes Deployments
Docker Compose files
What is the primary purpose of Docker Swarm?
Scanning Docker images for vulnerabilities
Storing and versioning Docker images
Building Docker images faster
Deploying and managing containerized applications at scale
Which of the following is NOT a valid health check type in a Dockerfile?
CMD
TCP
NONE
HTTP
How can you invalidate the Docker build cache for a specific instruction?
By modifying the instruction itself.
All of the above.
By deleting the corresponding image layer.
By using the --no-cache flag during the build process.
--no-cache
You've scaled a service in Docker Compose, but now want to revert to a single instance. How do you achieve this?
Docker Compose automatically handles this, no manual intervention needed
Use docker-compose down followed by docker-compose up
docker-compose down
docker-compose up
Execute docker-compose restart <service_name>
docker-compose restart <service_name>
Utilize docker-compose scale <service_name>=1
docker-compose scale <service_name>=1
What is the purpose of the 'docker push' command in the context of a Docker Registry?
Download an image from a registry
Upload an image to a registry
Run a Docker container from an image
Build a Docker image from a Dockerfile
Which command is used to initialize a Docker Swarm?
docker swarm up
docker swarm start
docker swarm init
docker swarm create
Which data persistence approach provides the highest level of isolation between the host system and container data?
Docker volumes.
Directly writing data to the container's filesystem.
Bind mounts.
Using a shared network drive.
What is the primary function of a Docker Registry?
Storing and distributing Docker images
Running Docker containers in production
Managing network traffic between containers
Building Docker images
What is the primary advantage of using Docker containers in a CI/CD pipeline?
Elimination of the need for version control
Reduced storage footprint for build artifacts
Guaranteed execution on any operating system
Enhanced environment consistency across development, testing, and production