When you run docker-compose up -d , by default the build image will contain the name of the current folder.
So for example, for this docker-compose.yml file, my image will be called: dockersymfony_php , because my current folder is called docker-symfony , and I specified php for my image in my yaml file
php: build: ./docker/php container_name: symfony
Is there a way to override this? Like content_name to rename container ...
I know the docker build -t command. can do this, but I need to use the docker-compose.yml file .
Kevin source share