Closed StefanScherer closed 1 year ago
I've been thinking for a little bit that we should have written guidelines/opinions on how the Compose files should be structured and best practices around them. The usage of the container name (or lack thereof really) should definitely be in it. I can make that part of my idea list as we're looking to help take over maintaining.
LGTM!
During a test I wanted to create a second dev environment for the react-express-mongo example, but it failed, because the container name "mongo" is already in use by a stopped other dev env.
I suggest to remove the
container_name
from the Docker Compose file, because Compose automatically assigns the service name and service lookup via host names work fine. The whole app still works fine.