Open sayanarijit opened 5 years ago
Example: How docker compose is being used in warehouse: https://github.com/pypa/warehouse/blob/master/docker-compose.yml
Is there something else I need to install? As long as the "API" of make commands don't change and I don't have to tell people to install yet another dependency, I don't mind.
If, however, there are extra roadblocks for people to set up the env, then the benefits must vastly outweigh the cons (which in this case, is longer onboarding).
There's no extra dependency in mac and windows i.e. machines running "docker machine". Since docker is native to linux and doesn't need "docker machine" to be installed, installing docker-ce won't install docker-compose. So we have to instruct linux users to install docker-compose. Is that okay?
Other api and make targets should stay the same.
Example instructions: https://warehouse.readthedocs.io/development/getting-started/#install-docker-compose
Not ideal, but I do see the benefits. Could you please prepare a PR so we can all see how it would look?
There are some lengthy docker commands in the
Makefle
e.g. https://github.com/niteoweb/pyramid-realworld-example-app/blob/master/Makefile#L28 https://github.com/niteoweb/pyramid-realworld-example-app/blob/master/Makefile#L34 https://github.com/niteoweb/pyramid-realworld-example-app/blob/master/Makefile#L39Docker compose let's us define the default properties of all the containers in a yaml file so that the management commands become clean and minimal.
Docker compose also comes with several other goodies such as workspace specific network, auto unique container names etc. to avoid conflicting with other docker containers on the dev's machine.
It's also easy to run and debug containers with docker compose as no container has to be put in the background and all can print outputs in a single session on the terminal.
So I think it will be beneficial to use docker compose instead of raw docker commands. Opinions?