701-100 Exam QuestionsBrowse all questions from this exam

701-100 Exam - Question 29


Which of the following tasks are completed by docker-compose down when it is used with additional parameters? (Choose two correct answers.)

Show Answer
Correct Answer: ACD

When using docker-compose down with additional parameters, it can delete all volumes defined in the composer file if the -v or --volumes option is specified. It can also delete all images used in the composer file from the Docker nodes if the --rmi option with 'all' or 'local' type is used. By default, it removes containers and networks defined in the composer file, but these are not dependent on additional parameters.

Discussion

12 comments
Sign in to comment
cecocenovOptions: AD
Apr 14, 2021

A and D. Usage: down [options] Options: --rmi type Remove images. Type must be one of: 'all': Remove all images used by any service. 'local': Remove only images that don't have a custom tag set by the `image` field. -v, --volumes Remove named volumes declared in the `volumes` section of the Compose file and anonymous volumes attached to containers. --remove-orphans Remove containers for services not defined in the Compose file -t, --timeout TIMEOUT Specify a shutdown timeout in seconds. (default: 10)

txui555Options: AD
Sep 29, 2021

BC would be the option by defaul BUT it can not be because it says "when it is used with additional parameters", so AD

hector1978Options: BC
Feb 17, 2020

It does not delete the volumes, but it does delete the containers. the correct answer is B and C

Blob21Options: AD
Jun 23, 2021

A and D seem correct

[Removed]Options: AD
Mar 2, 2022

AD is real correct. "docker-compose down" remove network and container. If you apply arguments, you can remove volumes and/or images.

marmoladaOptions: AB
Sep 3, 2020

c is incorrect, networks are removed by default. You don't need to specify additional option to remove it

hmagrounOptions: BC
Mar 25, 2020

The correct answer is B and C https://docs.docker.com/compose/reference/down/

mucmikeOptions: AC
Jun 10, 2020

No, it´s A and C -v, --volumes Remove named volumes declared in the `volumes` section of the Compose file and anonymous volumes attached to containers.

matrpro
Aug 15, 2020

Which of the following tasks are completed by docker-compose down when it is used with additional parameters?

gilbertlelanceloOptions: AD
Aug 2, 2021

In reference to https://docs.docker.com/compose/reference/down/ --rmi type Remove images. Type must be one of: 'all': Remove all images used by any service. 'local': Remove only images that don't have a custom tag set by the `image` field. -v, --volumes Remove named volumes declared in the `volumes` section of the Compose file and anonymous volumes attached to containers. Ans is A & D

[Removed]Options: BC
Aug 25, 2021

B & C is correct From docker-compose help By default, the only things removed are: - Containers for services defined in the Compose file - Networks defined in the `networks` section of the Compose file - The default network, if one is used

[Removed]Options: AC
Mar 1, 2022

docker-compose down Usage: docker-compose down [options] Options: --rmi type Remove images. Type must be one of: 'all': Remove all images used by any service. 'local': Remove only images that don't have a custom tag set by the `image` field. -v, --volumes Remove named volumes declared in the `volumes` section of the Compose file and anonymous volumes attached to containers. --remove-orphans Remove containers for services not defined in the Compose file -t, --timeout TIMEOUT Specify a shutdown timeout in seconds. (default: 10) Stops containers and removes containers, networks, volumes, and images created by up. By default, the only things removed are: Containers for services defined in the Compose file Networks defined in the networks section of the Compose file The default network, if one is used