Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to open/run YML compose file?

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

like image 736
dstr Avatar asked Jun 05 '17 08:06

dstr


People also ask

Where is the docker compose yml file?

The Compose file is a YAML file defining services, networks and volumes. The default path for a Compose file is ./docker-compose.yml .

How do I open a YAML file in Linux?

You can open a YAML file in any text editor, such as Microsoft Notepad (Windows) or Apple TextEdit (Mac). However, if you intend to edit a YAML file, you should open it using a source code editor, such as NotePad++ (Windows) or GitHub Atom (cross-platform).


1 Answers

If you are asking how to open YAML files, then you can use some common editors like NotePad++ in windows or vim in linux. If your question is about running the compose yaml file, then run this command from the directory where compose file is residing:

docker-compose -f {compose file name} up 

You can avoid -f if your filename is docker-compose.yml

like image 176
humblebee Avatar answered Oct 07 '22 22:10

humblebee