Reputation: 2262
I'm using Cookiecutter scaffold for my Django project and I follow the same workflow documented for local docker environments. I have a dev.yml compose file for a local setup. I have a testing env setup which is very different from a local setup(installs test dependencies, has different set of services specific to testing) called test.yml. I'm not able to spin up docker compose envs for both local development and testing env simultaneously. When I do a:
$ docker-compose -f dev.yml up -d
All the dev containers spin up fine.
After this I do a:
$ docker-compose -f test.yml up -d
It just recreates all the above containers. Should I use a different network? Or should I give different names for the apps and services in test.yml? What is the best practice to run different set of docker compose envs for the same codebase simultaneously?
Currently, I checkout the code in a different path and spin up the test env there, which seems to work.
Upvotes: 0
Views: 285