Update docker-compose run --rm doc (#6803)

* Update docker-compose run --rm doc

To make the functionality added in
24ab933ebf
explicit in the docs

* Rewrite change as an addendum

Rewrite the change to the end of the page as an addendum to the description of the inner workings of the run command.
This commit is contained in:
Oren 2018-06-20 00:58:30 +03:00 committed by Joao Fernandes
parent 7ee5554905
commit f490bd1752
1 changed files with 6 additions and 0 deletions

View File

@ -56,3 +56,9 @@ This opens an interactive PostgreSQL shell for the linked `db` container.
If you do not want the `run` command to start linked containers, use the `--no-deps` flag:
docker-compose run --no-deps web python manage.py shell
If you want to remove the container after running while overriding the container's restart policy, use the `--rm` flag:
docker-compose run --rm web python manage.py db upgrade
This runs a database upgrade script, and removes the container when finished running, even if a restart policy is specified in the service configuration.