How to run YML compose file?

+2 votes

How can I open a YML compose file on my computer? I've installed Docker for Windows and Docker tools but couldn't figure out how to do it.

Sep 7, 2018 in DevOps & Agile by Sophie may
• 10,100 points
58,591 views

4 answers to this question.

+1 vote

To run and open .yml files you have to install Docker Compose.

After the installation, go to your docker-compose.yml directory and then execute docker-compose up to create and start services in your docker-compose.yml file.

answered Sep 7, 2018 by Tyrion anex
• 8,560 points
This only works if the file is named `docker-compose.yml`, which I think is the big gotcha that new users face because this isn't even mentioned by most tutorials. You have to use `docker-compose -f MyFile.yml up` if you want to name your file anything else.
0 votes
You can open the yaml file using any sort of editor like Notepad++.
answered May 6, 2019 by Yesha
+1 vote

You can run the following command to run the docker-compose.yaml file:

docker-compose -f {compose file name} up

You can ignore the -f flag if your file name is docker-compose.yaml

answered May 6, 2019 by Mithin
0 votes

To manage and run docker-compose files, you need to install docker compose. Have a look at the documentation to install Docker compose for windows.

Once the installation is done, go to your docker-compose.yml directory and then execute docker-compose to create and start services in your docker-compose.yml file.

answered May 6, 2019 by Yamini

Related Questions In DevOps & Agile

+1 vote
2 answers

How do I run Apache server from Docker without mapping to a location?

If you're seeing a 500 error, that's ...READ MORE

answered Oct 18, 2018 in DevOps & Agile by lina
• 8,220 points
673 views
0 votes
1 answer

How to edit file after I shell to a docker container?

Since docker images are trimmed to bare minimum ...READ MORE

answered Sep 11, 2018 in DevOps & Agile by Damon Salvatore
• 5,550 points
1,225 views
0 votes
1 answer
+2 votes
1 answer
+2 votes
1 answer

Deploy Docker Containers from Docker Cloud

To solve this problem, I followed advice ...READ MORE

answered Sep 3, 2018 in AWS by Priyaj
• 57,700 points
908 views
0 votes
1 answer

How to a run deployed app in Docker for Windows?

To deploy an ASP.NET web application to ...READ MORE

answered Aug 29, 2018 in DevOps & Agile by Tyrion anex
• 8,560 points
222 views
0 votes
2 answers

How does Docker for Windows run Linux containers?

One of the most important enhancements is ...READ MORE

answered Aug 29 in DevOps & Agile by Pistle
• 1,000 points
176 views