wayground logo

Free Printable Worksheets

NEW

Font size

S
M
L
XL
Worksheets

Docker fundamentals

Total questions: 12

Worksheet time: 6mins

Name
Class
Date
1.

Docker command to list all the images

a)

docker load -i drupal.tar

b)

docker ps

c)

docker images

d)

docker ps -a

2.

Docker command to see all the containers

a)

docker images

b)

docker version

c)

docker ps

d)

docker ps -a

3.

Docker command to see only running containers

a)

docker ps -a

b)

docker images

c)

docker ps

d)

docker version

4.

Docker command to check the IP address of container

a)

docker ps -a

b)

docker logs websrv

c)

docker images

d)

docker inspect websrv

5.

Docker command to find out the cause of container exit with error.

a)

docker logs websrv

b)

docker inspect websrv

c)

docker ps -a

d)

docker ps

6.

Docker command to enter into a container

a)

docker inspect dbsrv

b)

docker logs dbsrv

c)

docker exec -it dbsrv bash

d)

docker ps -a

7.

How do containers differ from virtual machines?

a)

Containers include a full operating system

b)

Containers use more memory

c)

Containers share the host OS kernel

d)

Containers cannot be networked

8.

In Docker, volumes are used to:

a)

Run containers in parallel

b)

Encrypt container data

c)

Persist data outside containers

9.

By default, when a container is removed, changes made to the container is kept safe.

a)

true

b)

false

10.

What is the purpose of docker-compose?

a)

To monitor Docker containers

b)

To define and run multi-container Docker applications

c)

To upload images to Docker Hub

11.

What is the main benefit of using containers in software development?

a)

They eliminate the need for source code

b)

They require no configuration

c)

They provide consistency across different environments

d)

They are free to use.

12.

Which of the following best explains “port mapping” in Docker?

a)

It opens a firewall port

b)

It assigns new IP addresses

c)

It connects the container’s internal port to a port on the host