How to install docker-compose on Windows











up vote
32
down vote

favorite
21












If I type the following commands in boot2docker as shown on the docker website:



curl -L https://github.com/docker/compose/releases/download/1.1.0/docker-compose-`uname -s`-`uname -m` > /usr/local/bin/docker-compose
chmod +x /usr/local/bin/docker-compose


When I type the following commands to check if the installation was successful, I get:



/usr/local/bin/docker-compose: line 1: syntax error: unexpected newline


So, how can I install docker-compose on boot2docker ?










share|improve this question




















  • 1




    I have edited my answer below, after Ed's feedback: installing docker-compose directly in boot2docker (instead of trying to run it in a container) seems the more robust solution.
    – VonC
    Jun 8 '15 at 15:55















up vote
32
down vote

favorite
21












If I type the following commands in boot2docker as shown on the docker website:



curl -L https://github.com/docker/compose/releases/download/1.1.0/docker-compose-`uname -s`-`uname -m` > /usr/local/bin/docker-compose
chmod +x /usr/local/bin/docker-compose


When I type the following commands to check if the installation was successful, I get:



/usr/local/bin/docker-compose: line 1: syntax error: unexpected newline


So, how can I install docker-compose on boot2docker ?










share|improve this question




















  • 1




    I have edited my answer below, after Ed's feedback: installing docker-compose directly in boot2docker (instead of trying to run it in a container) seems the more robust solution.
    – VonC
    Jun 8 '15 at 15:55













up vote
32
down vote

favorite
21









up vote
32
down vote

favorite
21






21





If I type the following commands in boot2docker as shown on the docker website:



curl -L https://github.com/docker/compose/releases/download/1.1.0/docker-compose-`uname -s`-`uname -m` > /usr/local/bin/docker-compose
chmod +x /usr/local/bin/docker-compose


When I type the following commands to check if the installation was successful, I get:



/usr/local/bin/docker-compose: line 1: syntax error: unexpected newline


So, how can I install docker-compose on boot2docker ?










share|improve this question















If I type the following commands in boot2docker as shown on the docker website:



curl -L https://github.com/docker/compose/releases/download/1.1.0/docker-compose-`uname -s`-`uname -m` > /usr/local/bin/docker-compose
chmod +x /usr/local/bin/docker-compose


When I type the following commands to check if the installation was successful, I get:



/usr/local/bin/docker-compose: line 1: syntax error: unexpected newline


So, how can I install docker-compose on boot2docker ?







windows docker boot2docker docker-compose






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Aug 29 '15 at 19:53









Josh

90811014




90811014










asked Mar 26 '15 at 22:07









Chris

62221017




62221017








  • 1




    I have edited my answer below, after Ed's feedback: installing docker-compose directly in boot2docker (instead of trying to run it in a container) seems the more robust solution.
    – VonC
    Jun 8 '15 at 15:55














  • 1




    I have edited my answer below, after Ed's feedback: installing docker-compose directly in boot2docker (instead of trying to run it in a container) seems the more robust solution.
    – VonC
    Jun 8 '15 at 15:55








1




1




I have edited my answer below, after Ed's feedback: installing docker-compose directly in boot2docker (instead of trying to run it in a container) seems the more robust solution.
– VonC
Jun 8 '15 at 15:55




I have edited my answer below, after Ed's feedback: installing docker-compose directly in boot2docker (instead of trying to run it in a container) seems the more robust solution.
– VonC
Jun 8 '15 at 15:55












10 Answers
10






active

oldest

votes

















up vote
39
down vote



accepted










Update 7th of november 2018:




On desktop systems like Docker for Mac and Windows, Docker Compose is
included as part of those desktop installs.




Accordingly to the documentation, Docker for Windows and Docker Toolbox already include Compose along with other Docker apps, so most Windows users do not need to install Compose separately.





Update 2017: this is now officially managed (for Windows 10 supporting Hyper-V) with "Docker for Windows".

See "Install Docker for Windows".

It does have a chocolatey installation package for Docker, so:



choco install docker-for-windows 
# or
choco upgrade docker-for-windows


Again, this requires a 64bit Windows 10 Pro, Enterprise and Education (1511 November update, Build 10586 or later) and Microsoft Hyper-V.



For other Windows, you still need VirtualBox + Boot2Docker.





Update: docker compose 1.5 (Nov 2015) should make it officially available for Windows (since RC2).



Pull requests like PR 2230 and PR 2143 helped.
Commit 13d5efc details the official Build process for the Windows binary.





Original answer (Q1-Q3 2015).



Warning: the original answer ("docker-compose in a container") below seems to have a bug, according to Ed Morley (edmorley).




There appear to be caching issues with the "docker-compose in a container" method (See issue #6: "Changes to docker-compose.yml and Dockerfile not being detected")




Ed recommends:




As such for now, running the Python docker-compose package inside boot2docker seems to be the most reliable solution for Windows users (having spent many hours trying to battle with the alternatives).



To install docker-compose from PyPI, run this from inside boot2docker:




docker@boot2docker:~$ 
tce-load -wi python && curl https://bootstrap.pypa.io/get-pip.py |
sudo python - && sudo pip install -U docker-compose



To save having to run the above every time the boot2docker VM is restarted (since changes don't persist), you can use bootlocal.sh like so:




docker@boot2docker:~$ 
echo 'su docker -c "tce-load -wi python" &&
curl https://bootstrap.pypa.io/get-pip.py |
python - && pip install -U docker-compose' |
sudo tee /var/lib/boot2docker/bootlocal.sh > /dev/null &&
sudo chmod +x /var/lib/boot2docker/bootlocal.sh



(The su docker -c gymnastics are required since tce-load cannot be run as root, and bootlocal.sh is run as root. The chmod of bootlocal.sh should be unnecessary once #915 is fixed.

Add -a to the tee command if you need to append, rather than overwrite bootlocal.sh.)



If you wish to use a pre-release version of docker-compose, then replace pip install -U docker-compose with pip install -U docker-compose>=1.3.0rc1 or equivalent.






Original answer:



I also run docker-compose (on Windows boot2docker) in a image by:




  • cloning https://github.com/docker/compose in /c/Users/<username>/myproject/compose (in order to have persistence, since /c/Users/<username> is automatically mounted, when I use VirtualBox with its extension pack )


  • building the docker-compose image:



    cd /c/Users/<username>/myproject/compose
    # that will put the repo in a detached HEAD, but it does not matter here
    git checkout 1.2.0
    docker build -t docker-compose .



  • adding a 'dc' alias (in a profile file that I copy to my /home/docker/.ashrc before launching the boot2docker ssh session.)



    dc='docker run --rm -i -t -v /var/run/docker.sock:/var/run/docker.sock -v `pwd`:`pwd` -w `pwd` docker-compose'



From there, a 'dc up' or 'dc ps' just works. On Windows. With boot2docker 1.6.






share|improve this answer



















  • 5




    You don't even have to clone the repo, simply do docker build -t docker-compose github.com/docker/compose and docker will clone and build the repository
    – thaJeztah
    Apr 20 '15 at 20:35






  • 1




    @thaJeztah true. In my case, docker-compose is a submodule of my repo (github.com/VonC/b2d), and I wanted to checkout that docker-compose submodule to a specific tag, in order to build a stable version.
    – VonC
    Apr 20 '15 at 20:36








  • 1




    Strange, my boot2docker VM won't persist the docker-compose installation even after running the second step echo 'su...
    – Anthony F.
    Jun 18 '15 at 15:53






  • 1




    @AnthonyF. Indeed. I only tested the image option. You can mention it in issue 603, although after reading github.com/boot2docker/boot2docker/issues/…, I would wait for docker and boot2docker 1.7.
    – VonC
    Jun 18 '15 at 16:53






  • 2




    @tiagoperes Thank you for the edit!
    – VonC
    Nov 7 at 18:27


















up vote
11
down vote













There is one more solution of running docker-compose under Windows using Babun (a famous port of Cygwin shell with all kinds of enhancements, including a package manager).



Here is how:



1.) Install Babun
2.) Open it and instal required dependencies for Python and Pip:



pact install python-setuptools 
pact install libxml2-devel libxslt-devel libyaml-devel
curl -skS https://bootstrap.pypa.io/get-pip.py | python
pip install virtualenv
curl -skS https://raw.githubusercontent.com/mitsuhiko/pipsi/master/get-pipsi.py | python


3.) Finally run



pip install -U docker-compose


The solution is not mine, taken from here: http://habrahabr.ru/post/260329/



I have a strong opinion, that docker-compose must be installed on a host, not a boot2docker VM, so you don't need to ssh all the time.






share|improve this answer




























    up vote
    6
    down vote













    You can install docker-compose on Windows with pip:



    pip install -U docker-compose





    share|improve this answer

















    • 1




      The command for me was actually: python -m pip install -U pip
      – Ev Haus
      May 9 '15 at 17:26








    • 4




      You can indeed, but when running docker-compose up it raises ImportError: No module named 'fcntl'
      – LaundroMat
      May 14 '15 at 6:27






    • 1




      This solution doesn't work. The installed package is unusable (I get the same error as @LaundroMat).
      – André Caron
      May 19 '15 at 20:03






    • 3




      I was able to use docker-compose successfully using windows and Babun. Simply follow this guide to install pip and babun, and then call pip install -U docker-compose
      – mcmil
      May 20 '15 at 16:08






    • 1




      @mcmil For the record, I keep having the same problem unfortunately. (It's not that big of a problem for me, but it's of course a pity).
      – LaundroMat
      May 22 '15 at 8:53


















    up vote
    5
    down vote













    It seems they haven't added native support into the Windows version of Boot2Docker yet.



    So for the moment, you can use docker-compose as how you've done with fig previously: run it as a docker container.






    share|improve this answer

















    • 1




      boot2docker has native support on Windows now
      – RadiantHex
      May 4 '15 at 0:34






    • 1




      alias docker-compose='docker run --rm -it -v $(pwd):/app -v /var/run/docker.sock:/var/run/docker.sock -e COMPOSE_PROJECT_NAME=$(basename $(pwd)) dduportal/docker-compose'
      – Sowry
      May 7 '15 at 11:31






    • 2




      This works for me with bash/Cygwin: alias docker-compose="docker run -v "$(pwd)":/app dduportal/docker-compose:latest"
      – user11153
      May 20 '15 at 13:03






    • 1




      Running in a container might not always work. See my edited answer below, after Ed's feedback.
      – VonC
      Jun 8 '15 at 15:54


















    up vote
    5
    down vote













    boot2docker versions >= 1.7.0 have 64 bits userspace. This means that prebuilt binaries from their github repository are working out of the box.



    I have used the information in VonC's answer above to write a script that downloads the latest version (or a specific version, see the commented part in the code) and persists it. It will only download the file once, but it will put it on the path on every startup of boot2docker.



    Instructions:





    1. boot2docker ssh from any terminal.

    2. paste the script and press enter.


    3. exit and then run boot2docker restart && boot2docker ssh

    4. When the box is restarted, run docker-compose to see that it responds with its command list.


    On Windows, the boot2docker restart command has a tendency to fail the first time. But it is just to run that command again.



    echo 'if [ ! -f /var/lib/boot2docker/etc/docker-compose-`uname -s`-`uname -m` ]; then
    echo "Download docker-compose..."
    # Download latest version
    curl -L https://github.com/docker/compose/releases/download/$(curl -s -L https://github.com/docker/compose/releases/latest |
    grep -Eo -m 1 docker/compose/releases/tag/([0-9.]*) |
    grep -o [0-9.]*)/docker-compose-`uname -s`-`uname -m`
    > /var/lib/boot2docker/etc/docker-compose-`uname -s`-`uname -m`
    # Download fixed version
    # curl -L https://github.com/docker/compose/releases/download/1.3.1/docker-compose-`uname -s`-`uname -m`
    # > /var/lib/boot2docker/etc/docker-compose-`uname -s`-`uname -m`
    echo "Done!"
    fi
    echo "Install docker-compose on path..."
    cp /var/lib/boot2docker/etc/docker-compose-`uname -s`-`uname -m` /usr/local/bin/docker-compose &&
    chmod +x /usr/local/bin/docker-compose
    echo "Done!"
    ' | sudo tee /var/lib/boot2docker/bootlocal.sh > /dev/null &&
    sudo chmod +x /var/lib/boot2docker/bootlocal.sh





    share|improve this answer



















    • 1




      That looks great, +1
      – VonC
      Jul 10 '15 at 7:26


















    up vote
    4
    down vote













    Things have progressed and lately, I've had the most success with the following method, which allows you to run it natively on Windows, by using Docker.



    First, you'll want to install the Docker CLI for Windows:



    curl -L https://get.docker.com/builds/Windows/x86_64/docker-latest.exe > /usr/bin/docker
    chmod +x /usr/bin/docker


    Next, build the docker-compose image from the Github repository:



    docker build -t docker-compose github.com/docker/compose


    Then, simply set up an alias to run the container:



    alias docker-compose='docker run --rm -ti -v /var/run/docker.sock:/var/run/docker.sock -v `pwd`:`pwd` -w `pwd` docker-compose'


    I've been using this for a while now and haven't ran into any problems -- the functionality is exactly what you'd expect as if using the binary natively, you just need to make sure your shared folders are mapped correctly into the B2D/Docker-Machine VM. I find it easiest to mirror the paths in the VM as they are on the host so my docker-compose.yml file isn't quite so confusing.






    share|improve this answer




























      up vote
      4
      down vote













      I got success following this issue on github




      • install docker-machine;

      • install python (3.4.3 worked fine)

      • install pip;


      • after pip... run this command to install docker-compose:



        `pip install git+git://github.com/docker/compose.git`



      Not believing? watch this proof






      share|improve this answer






























        up vote
        3
        down vote













        https://github.com/docker/compose/releases/tag/1.5.0rc3 "Compose is now available for Windows."






        share|improve this answer




























          up vote
          3
          down vote













          The easiest way to install Docker Compose (and Docker) on Windows, is to use the chocolatey (a package manager for Windows) package docker-compose, which should be installed after the package docker. This will free you from the many obstacles, when installing it manually and gives you an easy way to update your installation.



          If you´re not familiar with chocolatey, just install it - e.g. on a administrative commandline with:



          @powershell -NoProfile -ExecutionPolicy Bypass -Command "iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))" && SET "PATH=%PATH%;%ALLUSERSPROFILE%chocolateybin"


          Now that chocolatey is installed, the only thing that´s left is to fire up a administrative Powershell and do:



          choco install docker
          choco install docker-compose


          As a sidenote: You don´t need Boot2Docker anymore to run Docker on Windows - Docker natively support´s Windows for some time now. So no need for that anymore.






          share|improve this answer




























            up vote
            2
            down vote













            This has been my go-to answer for getting Compose installed inside of boot2docker. If anyone would like to entertain VonC's suggestion to run Compose against their host's Docker host from within a container, I've created a journeyman developer's container that follows Compose's guidelines and is easy to install and run.



            If you have a Bourne shell-like environment on Windows, you can simply run:



            curl -L https://git.io/vuEqk -o /usr/local/bin/room
            chmod +x /usr/local/bin/room


            You can start a container on any path and take it from there by simply running:



            room


            You can optionally pass command arguments, so if you find yourself in a working directory that has a Compose configuration file, this would suffice to get everything up and running:



            room docker-compose up


            If your missing a supportive shell environment, installing one of the Git distributions for Windows which include the Git Bash prompt would suffice or you can directly use the prompts from one of either MinGW or Cygwin. If not, you can always SSH into your Docker Machine and install there.






            share|improve this answer























              Your Answer






              StackExchange.ifUsing("editor", function () {
              StackExchange.using("externalEditor", function () {
              StackExchange.using("snippets", function () {
              StackExchange.snippets.init();
              });
              });
              }, "code-snippets");

              StackExchange.ready(function() {
              var channelOptions = {
              tags: "".split(" "),
              id: "1"
              };
              initTagRenderer("".split(" "), "".split(" "), channelOptions);

              StackExchange.using("externalEditor", function() {
              // Have to fire editor after snippets, if snippets enabled
              if (StackExchange.settings.snippets.snippetsEnabled) {
              StackExchange.using("snippets", function() {
              createEditor();
              });
              }
              else {
              createEditor();
              }
              });

              function createEditor() {
              StackExchange.prepareEditor({
              heartbeatType: 'answer',
              convertImagesToLinks: true,
              noModals: true,
              showLowRepImageUploadWarning: true,
              reputationToPostImages: 10,
              bindNavPrevention: true,
              postfix: "",
              imageUploader: {
              brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
              contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
              allowUrls: true
              },
              onDemand: true,
              discardSelector: ".discard-answer"
              ,immediatelyShowMarkdownHelp:true
              });


              }
              });














               

              draft saved


              draft discarded


















              StackExchange.ready(
              function () {
              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f29289785%2fhow-to-install-docker-compose-on-windows%23new-answer', 'question_page');
              }
              );

              Post as a guest















              Required, but never shown

























              10 Answers
              10






              active

              oldest

              votes








              10 Answers
              10






              active

              oldest

              votes









              active

              oldest

              votes






              active

              oldest

              votes








              up vote
              39
              down vote



              accepted










              Update 7th of november 2018:




              On desktop systems like Docker for Mac and Windows, Docker Compose is
              included as part of those desktop installs.




              Accordingly to the documentation, Docker for Windows and Docker Toolbox already include Compose along with other Docker apps, so most Windows users do not need to install Compose separately.





              Update 2017: this is now officially managed (for Windows 10 supporting Hyper-V) with "Docker for Windows".

              See "Install Docker for Windows".

              It does have a chocolatey installation package for Docker, so:



              choco install docker-for-windows 
              # or
              choco upgrade docker-for-windows


              Again, this requires a 64bit Windows 10 Pro, Enterprise and Education (1511 November update, Build 10586 or later) and Microsoft Hyper-V.



              For other Windows, you still need VirtualBox + Boot2Docker.





              Update: docker compose 1.5 (Nov 2015) should make it officially available for Windows (since RC2).



              Pull requests like PR 2230 and PR 2143 helped.
              Commit 13d5efc details the official Build process for the Windows binary.





              Original answer (Q1-Q3 2015).



              Warning: the original answer ("docker-compose in a container") below seems to have a bug, according to Ed Morley (edmorley).




              There appear to be caching issues with the "docker-compose in a container" method (See issue #6: "Changes to docker-compose.yml and Dockerfile not being detected")




              Ed recommends:




              As such for now, running the Python docker-compose package inside boot2docker seems to be the most reliable solution for Windows users (having spent many hours trying to battle with the alternatives).



              To install docker-compose from PyPI, run this from inside boot2docker:




              docker@boot2docker:~$ 
              tce-load -wi python && curl https://bootstrap.pypa.io/get-pip.py |
              sudo python - && sudo pip install -U docker-compose



              To save having to run the above every time the boot2docker VM is restarted (since changes don't persist), you can use bootlocal.sh like so:




              docker@boot2docker:~$ 
              echo 'su docker -c "tce-load -wi python" &&
              curl https://bootstrap.pypa.io/get-pip.py |
              python - && pip install -U docker-compose' |
              sudo tee /var/lib/boot2docker/bootlocal.sh > /dev/null &&
              sudo chmod +x /var/lib/boot2docker/bootlocal.sh



              (The su docker -c gymnastics are required since tce-load cannot be run as root, and bootlocal.sh is run as root. The chmod of bootlocal.sh should be unnecessary once #915 is fixed.

              Add -a to the tee command if you need to append, rather than overwrite bootlocal.sh.)



              If you wish to use a pre-release version of docker-compose, then replace pip install -U docker-compose with pip install -U docker-compose>=1.3.0rc1 or equivalent.






              Original answer:



              I also run docker-compose (on Windows boot2docker) in a image by:




              • cloning https://github.com/docker/compose in /c/Users/<username>/myproject/compose (in order to have persistence, since /c/Users/<username> is automatically mounted, when I use VirtualBox with its extension pack )


              • building the docker-compose image:



                cd /c/Users/<username>/myproject/compose
                # that will put the repo in a detached HEAD, but it does not matter here
                git checkout 1.2.0
                docker build -t docker-compose .



              • adding a 'dc' alias (in a profile file that I copy to my /home/docker/.ashrc before launching the boot2docker ssh session.)



                dc='docker run --rm -i -t -v /var/run/docker.sock:/var/run/docker.sock -v `pwd`:`pwd` -w `pwd` docker-compose'



              From there, a 'dc up' or 'dc ps' just works. On Windows. With boot2docker 1.6.






              share|improve this answer



















              • 5




                You don't even have to clone the repo, simply do docker build -t docker-compose github.com/docker/compose and docker will clone and build the repository
                – thaJeztah
                Apr 20 '15 at 20:35






              • 1




                @thaJeztah true. In my case, docker-compose is a submodule of my repo (github.com/VonC/b2d), and I wanted to checkout that docker-compose submodule to a specific tag, in order to build a stable version.
                – VonC
                Apr 20 '15 at 20:36








              • 1




                Strange, my boot2docker VM won't persist the docker-compose installation even after running the second step echo 'su...
                – Anthony F.
                Jun 18 '15 at 15:53






              • 1




                @AnthonyF. Indeed. I only tested the image option. You can mention it in issue 603, although after reading github.com/boot2docker/boot2docker/issues/…, I would wait for docker and boot2docker 1.7.
                – VonC
                Jun 18 '15 at 16:53






              • 2




                @tiagoperes Thank you for the edit!
                – VonC
                Nov 7 at 18:27















              up vote
              39
              down vote



              accepted










              Update 7th of november 2018:




              On desktop systems like Docker for Mac and Windows, Docker Compose is
              included as part of those desktop installs.




              Accordingly to the documentation, Docker for Windows and Docker Toolbox already include Compose along with other Docker apps, so most Windows users do not need to install Compose separately.





              Update 2017: this is now officially managed (for Windows 10 supporting Hyper-V) with "Docker for Windows".

              See "Install Docker for Windows".

              It does have a chocolatey installation package for Docker, so:



              choco install docker-for-windows 
              # or
              choco upgrade docker-for-windows


              Again, this requires a 64bit Windows 10 Pro, Enterprise and Education (1511 November update, Build 10586 or later) and Microsoft Hyper-V.



              For other Windows, you still need VirtualBox + Boot2Docker.





              Update: docker compose 1.5 (Nov 2015) should make it officially available for Windows (since RC2).



              Pull requests like PR 2230 and PR 2143 helped.
              Commit 13d5efc details the official Build process for the Windows binary.





              Original answer (Q1-Q3 2015).



              Warning: the original answer ("docker-compose in a container") below seems to have a bug, according to Ed Morley (edmorley).




              There appear to be caching issues with the "docker-compose in a container" method (See issue #6: "Changes to docker-compose.yml and Dockerfile not being detected")




              Ed recommends:




              As such for now, running the Python docker-compose package inside boot2docker seems to be the most reliable solution for Windows users (having spent many hours trying to battle with the alternatives).



              To install docker-compose from PyPI, run this from inside boot2docker:




              docker@boot2docker:~$ 
              tce-load -wi python && curl https://bootstrap.pypa.io/get-pip.py |
              sudo python - && sudo pip install -U docker-compose



              To save having to run the above every time the boot2docker VM is restarted (since changes don't persist), you can use bootlocal.sh like so:




              docker@boot2docker:~$ 
              echo 'su docker -c "tce-load -wi python" &&
              curl https://bootstrap.pypa.io/get-pip.py |
              python - && pip install -U docker-compose' |
              sudo tee /var/lib/boot2docker/bootlocal.sh > /dev/null &&
              sudo chmod +x /var/lib/boot2docker/bootlocal.sh



              (The su docker -c gymnastics are required since tce-load cannot be run as root, and bootlocal.sh is run as root. The chmod of bootlocal.sh should be unnecessary once #915 is fixed.

              Add -a to the tee command if you need to append, rather than overwrite bootlocal.sh.)



              If you wish to use a pre-release version of docker-compose, then replace pip install -U docker-compose with pip install -U docker-compose>=1.3.0rc1 or equivalent.






              Original answer:



              I also run docker-compose (on Windows boot2docker) in a image by:




              • cloning https://github.com/docker/compose in /c/Users/<username>/myproject/compose (in order to have persistence, since /c/Users/<username> is automatically mounted, when I use VirtualBox with its extension pack )


              • building the docker-compose image:



                cd /c/Users/<username>/myproject/compose
                # that will put the repo in a detached HEAD, but it does not matter here
                git checkout 1.2.0
                docker build -t docker-compose .



              • adding a 'dc' alias (in a profile file that I copy to my /home/docker/.ashrc before launching the boot2docker ssh session.)



                dc='docker run --rm -i -t -v /var/run/docker.sock:/var/run/docker.sock -v `pwd`:`pwd` -w `pwd` docker-compose'



              From there, a 'dc up' or 'dc ps' just works. On Windows. With boot2docker 1.6.






              share|improve this answer



















              • 5




                You don't even have to clone the repo, simply do docker build -t docker-compose github.com/docker/compose and docker will clone and build the repository
                – thaJeztah
                Apr 20 '15 at 20:35






              • 1




                @thaJeztah true. In my case, docker-compose is a submodule of my repo (github.com/VonC/b2d), and I wanted to checkout that docker-compose submodule to a specific tag, in order to build a stable version.
                – VonC
                Apr 20 '15 at 20:36








              • 1




                Strange, my boot2docker VM won't persist the docker-compose installation even after running the second step echo 'su...
                – Anthony F.
                Jun 18 '15 at 15:53






              • 1




                @AnthonyF. Indeed. I only tested the image option. You can mention it in issue 603, although after reading github.com/boot2docker/boot2docker/issues/…, I would wait for docker and boot2docker 1.7.
                – VonC
                Jun 18 '15 at 16:53






              • 2




                @tiagoperes Thank you for the edit!
                – VonC
                Nov 7 at 18:27













              up vote
              39
              down vote



              accepted







              up vote
              39
              down vote



              accepted






              Update 7th of november 2018:




              On desktop systems like Docker for Mac and Windows, Docker Compose is
              included as part of those desktop installs.




              Accordingly to the documentation, Docker for Windows and Docker Toolbox already include Compose along with other Docker apps, so most Windows users do not need to install Compose separately.





              Update 2017: this is now officially managed (for Windows 10 supporting Hyper-V) with "Docker for Windows".

              See "Install Docker for Windows".

              It does have a chocolatey installation package for Docker, so:



              choco install docker-for-windows 
              # or
              choco upgrade docker-for-windows


              Again, this requires a 64bit Windows 10 Pro, Enterprise and Education (1511 November update, Build 10586 or later) and Microsoft Hyper-V.



              For other Windows, you still need VirtualBox + Boot2Docker.





              Update: docker compose 1.5 (Nov 2015) should make it officially available for Windows (since RC2).



              Pull requests like PR 2230 and PR 2143 helped.
              Commit 13d5efc details the official Build process for the Windows binary.





              Original answer (Q1-Q3 2015).



              Warning: the original answer ("docker-compose in a container") below seems to have a bug, according to Ed Morley (edmorley).




              There appear to be caching issues with the "docker-compose in a container" method (See issue #6: "Changes to docker-compose.yml and Dockerfile not being detected")




              Ed recommends:




              As such for now, running the Python docker-compose package inside boot2docker seems to be the most reliable solution for Windows users (having spent many hours trying to battle with the alternatives).



              To install docker-compose from PyPI, run this from inside boot2docker:




              docker@boot2docker:~$ 
              tce-load -wi python && curl https://bootstrap.pypa.io/get-pip.py |
              sudo python - && sudo pip install -U docker-compose



              To save having to run the above every time the boot2docker VM is restarted (since changes don't persist), you can use bootlocal.sh like so:




              docker@boot2docker:~$ 
              echo 'su docker -c "tce-load -wi python" &&
              curl https://bootstrap.pypa.io/get-pip.py |
              python - && pip install -U docker-compose' |
              sudo tee /var/lib/boot2docker/bootlocal.sh > /dev/null &&
              sudo chmod +x /var/lib/boot2docker/bootlocal.sh



              (The su docker -c gymnastics are required since tce-load cannot be run as root, and bootlocal.sh is run as root. The chmod of bootlocal.sh should be unnecessary once #915 is fixed.

              Add -a to the tee command if you need to append, rather than overwrite bootlocal.sh.)



              If you wish to use a pre-release version of docker-compose, then replace pip install -U docker-compose with pip install -U docker-compose>=1.3.0rc1 or equivalent.






              Original answer:



              I also run docker-compose (on Windows boot2docker) in a image by:




              • cloning https://github.com/docker/compose in /c/Users/<username>/myproject/compose (in order to have persistence, since /c/Users/<username> is automatically mounted, when I use VirtualBox with its extension pack )


              • building the docker-compose image:



                cd /c/Users/<username>/myproject/compose
                # that will put the repo in a detached HEAD, but it does not matter here
                git checkout 1.2.0
                docker build -t docker-compose .



              • adding a 'dc' alias (in a profile file that I copy to my /home/docker/.ashrc before launching the boot2docker ssh session.)



                dc='docker run --rm -i -t -v /var/run/docker.sock:/var/run/docker.sock -v `pwd`:`pwd` -w `pwd` docker-compose'



              From there, a 'dc up' or 'dc ps' just works. On Windows. With boot2docker 1.6.






              share|improve this answer














              Update 7th of november 2018:




              On desktop systems like Docker for Mac and Windows, Docker Compose is
              included as part of those desktop installs.




              Accordingly to the documentation, Docker for Windows and Docker Toolbox already include Compose along with other Docker apps, so most Windows users do not need to install Compose separately.





              Update 2017: this is now officially managed (for Windows 10 supporting Hyper-V) with "Docker for Windows".

              See "Install Docker for Windows".

              It does have a chocolatey installation package for Docker, so:



              choco install docker-for-windows 
              # or
              choco upgrade docker-for-windows


              Again, this requires a 64bit Windows 10 Pro, Enterprise and Education (1511 November update, Build 10586 or later) and Microsoft Hyper-V.



              For other Windows, you still need VirtualBox + Boot2Docker.





              Update: docker compose 1.5 (Nov 2015) should make it officially available for Windows (since RC2).



              Pull requests like PR 2230 and PR 2143 helped.
              Commit 13d5efc details the official Build process for the Windows binary.





              Original answer (Q1-Q3 2015).



              Warning: the original answer ("docker-compose in a container") below seems to have a bug, according to Ed Morley (edmorley).




              There appear to be caching issues with the "docker-compose in a container" method (See issue #6: "Changes to docker-compose.yml and Dockerfile not being detected")




              Ed recommends:




              As such for now, running the Python docker-compose package inside boot2docker seems to be the most reliable solution for Windows users (having spent many hours trying to battle with the alternatives).



              To install docker-compose from PyPI, run this from inside boot2docker:




              docker@boot2docker:~$ 
              tce-load -wi python && curl https://bootstrap.pypa.io/get-pip.py |
              sudo python - && sudo pip install -U docker-compose



              To save having to run the above every time the boot2docker VM is restarted (since changes don't persist), you can use bootlocal.sh like so:




              docker@boot2docker:~$ 
              echo 'su docker -c "tce-load -wi python" &&
              curl https://bootstrap.pypa.io/get-pip.py |
              python - && pip install -U docker-compose' |
              sudo tee /var/lib/boot2docker/bootlocal.sh > /dev/null &&
              sudo chmod +x /var/lib/boot2docker/bootlocal.sh



              (The su docker -c gymnastics are required since tce-load cannot be run as root, and bootlocal.sh is run as root. The chmod of bootlocal.sh should be unnecessary once #915 is fixed.

              Add -a to the tee command if you need to append, rather than overwrite bootlocal.sh.)



              If you wish to use a pre-release version of docker-compose, then replace pip install -U docker-compose with pip install -U docker-compose>=1.3.0rc1 or equivalent.






              Original answer:



              I also run docker-compose (on Windows boot2docker) in a image by:




              • cloning https://github.com/docker/compose in /c/Users/<username>/myproject/compose (in order to have persistence, since /c/Users/<username> is automatically mounted, when I use VirtualBox with its extension pack )


              • building the docker-compose image:



                cd /c/Users/<username>/myproject/compose
                # that will put the repo in a detached HEAD, but it does not matter here
                git checkout 1.2.0
                docker build -t docker-compose .



              • adding a 'dc' alias (in a profile file that I copy to my /home/docker/.ashrc before launching the boot2docker ssh session.)



                dc='docker run --rm -i -t -v /var/run/docker.sock:/var/run/docker.sock -v `pwd`:`pwd` -w `pwd` docker-compose'



              From there, a 'dc up' or 'dc ps' just works. On Windows. With boot2docker 1.6.







              share|improve this answer














              share|improve this answer



              share|improve this answer








              edited Nov 7 at 18:26









              tiagoperes

              2,22021432




              2,22021432










              answered Apr 19 '15 at 11:07









              VonC

              822k28425813096




              822k28425813096








              • 5




                You don't even have to clone the repo, simply do docker build -t docker-compose github.com/docker/compose and docker will clone and build the repository
                – thaJeztah
                Apr 20 '15 at 20:35






              • 1




                @thaJeztah true. In my case, docker-compose is a submodule of my repo (github.com/VonC/b2d), and I wanted to checkout that docker-compose submodule to a specific tag, in order to build a stable version.
                – VonC
                Apr 20 '15 at 20:36








              • 1




                Strange, my boot2docker VM won't persist the docker-compose installation even after running the second step echo 'su...
                – Anthony F.
                Jun 18 '15 at 15:53






              • 1




                @AnthonyF. Indeed. I only tested the image option. You can mention it in issue 603, although after reading github.com/boot2docker/boot2docker/issues/…, I would wait for docker and boot2docker 1.7.
                – VonC
                Jun 18 '15 at 16:53






              • 2




                @tiagoperes Thank you for the edit!
                – VonC
                Nov 7 at 18:27














              • 5




                You don't even have to clone the repo, simply do docker build -t docker-compose github.com/docker/compose and docker will clone and build the repository
                – thaJeztah
                Apr 20 '15 at 20:35






              • 1




                @thaJeztah true. In my case, docker-compose is a submodule of my repo (github.com/VonC/b2d), and I wanted to checkout that docker-compose submodule to a specific tag, in order to build a stable version.
                – VonC
                Apr 20 '15 at 20:36








              • 1




                Strange, my boot2docker VM won't persist the docker-compose installation even after running the second step echo 'su...
                – Anthony F.
                Jun 18 '15 at 15:53






              • 1




                @AnthonyF. Indeed. I only tested the image option. You can mention it in issue 603, although after reading github.com/boot2docker/boot2docker/issues/…, I would wait for docker and boot2docker 1.7.
                – VonC
                Jun 18 '15 at 16:53






              • 2




                @tiagoperes Thank you for the edit!
                – VonC
                Nov 7 at 18:27








              5




              5




              You don't even have to clone the repo, simply do docker build -t docker-compose github.com/docker/compose and docker will clone and build the repository
              – thaJeztah
              Apr 20 '15 at 20:35




              You don't even have to clone the repo, simply do docker build -t docker-compose github.com/docker/compose and docker will clone and build the repository
              – thaJeztah
              Apr 20 '15 at 20:35




              1




              1




              @thaJeztah true. In my case, docker-compose is a submodule of my repo (github.com/VonC/b2d), and I wanted to checkout that docker-compose submodule to a specific tag, in order to build a stable version.
              – VonC
              Apr 20 '15 at 20:36






              @thaJeztah true. In my case, docker-compose is a submodule of my repo (github.com/VonC/b2d), and I wanted to checkout that docker-compose submodule to a specific tag, in order to build a stable version.
              – VonC
              Apr 20 '15 at 20:36






              1




              1




              Strange, my boot2docker VM won't persist the docker-compose installation even after running the second step echo 'su...
              – Anthony F.
              Jun 18 '15 at 15:53




              Strange, my boot2docker VM won't persist the docker-compose installation even after running the second step echo 'su...
              – Anthony F.
              Jun 18 '15 at 15:53




              1




              1




              @AnthonyF. Indeed. I only tested the image option. You can mention it in issue 603, although after reading github.com/boot2docker/boot2docker/issues/…, I would wait for docker and boot2docker 1.7.
              – VonC
              Jun 18 '15 at 16:53




              @AnthonyF. Indeed. I only tested the image option. You can mention it in issue 603, although after reading github.com/boot2docker/boot2docker/issues/…, I would wait for docker and boot2docker 1.7.
              – VonC
              Jun 18 '15 at 16:53




              2




              2




              @tiagoperes Thank you for the edit!
              – VonC
              Nov 7 at 18:27




              @tiagoperes Thank you for the edit!
              – VonC
              Nov 7 at 18:27












              up vote
              11
              down vote













              There is one more solution of running docker-compose under Windows using Babun (a famous port of Cygwin shell with all kinds of enhancements, including a package manager).



              Here is how:



              1.) Install Babun
              2.) Open it and instal required dependencies for Python and Pip:



              pact install python-setuptools 
              pact install libxml2-devel libxslt-devel libyaml-devel
              curl -skS https://bootstrap.pypa.io/get-pip.py | python
              pip install virtualenv
              curl -skS https://raw.githubusercontent.com/mitsuhiko/pipsi/master/get-pipsi.py | python


              3.) Finally run



              pip install -U docker-compose


              The solution is not mine, taken from here: http://habrahabr.ru/post/260329/



              I have a strong opinion, that docker-compose must be installed on a host, not a boot2docker VM, so you don't need to ssh all the time.






              share|improve this answer

























                up vote
                11
                down vote













                There is one more solution of running docker-compose under Windows using Babun (a famous port of Cygwin shell with all kinds of enhancements, including a package manager).



                Here is how:



                1.) Install Babun
                2.) Open it and instal required dependencies for Python and Pip:



                pact install python-setuptools 
                pact install libxml2-devel libxslt-devel libyaml-devel
                curl -skS https://bootstrap.pypa.io/get-pip.py | python
                pip install virtualenv
                curl -skS https://raw.githubusercontent.com/mitsuhiko/pipsi/master/get-pipsi.py | python


                3.) Finally run



                pip install -U docker-compose


                The solution is not mine, taken from here: http://habrahabr.ru/post/260329/



                I have a strong opinion, that docker-compose must be installed on a host, not a boot2docker VM, so you don't need to ssh all the time.






                share|improve this answer























                  up vote
                  11
                  down vote










                  up vote
                  11
                  down vote









                  There is one more solution of running docker-compose under Windows using Babun (a famous port of Cygwin shell with all kinds of enhancements, including a package manager).



                  Here is how:



                  1.) Install Babun
                  2.) Open it and instal required dependencies for Python and Pip:



                  pact install python-setuptools 
                  pact install libxml2-devel libxslt-devel libyaml-devel
                  curl -skS https://bootstrap.pypa.io/get-pip.py | python
                  pip install virtualenv
                  curl -skS https://raw.githubusercontent.com/mitsuhiko/pipsi/master/get-pipsi.py | python


                  3.) Finally run



                  pip install -U docker-compose


                  The solution is not mine, taken from here: http://habrahabr.ru/post/260329/



                  I have a strong opinion, that docker-compose must be installed on a host, not a boot2docker VM, so you don't need to ssh all the time.






                  share|improve this answer












                  There is one more solution of running docker-compose under Windows using Babun (a famous port of Cygwin shell with all kinds of enhancements, including a package manager).



                  Here is how:



                  1.) Install Babun
                  2.) Open it and instal required dependencies for Python and Pip:



                  pact install python-setuptools 
                  pact install libxml2-devel libxslt-devel libyaml-devel
                  curl -skS https://bootstrap.pypa.io/get-pip.py | python
                  pip install virtualenv
                  curl -skS https://raw.githubusercontent.com/mitsuhiko/pipsi/master/get-pipsi.py | python


                  3.) Finally run



                  pip install -U docker-compose


                  The solution is not mine, taken from here: http://habrahabr.ru/post/260329/



                  I have a strong opinion, that docker-compose must be installed on a host, not a boot2docker VM, so you don't need to ssh all the time.







                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered Jul 30 '15 at 9:50









                  Ross Ivantsiv

                  425613




                  425613






















                      up vote
                      6
                      down vote













                      You can install docker-compose on Windows with pip:



                      pip install -U docker-compose





                      share|improve this answer

















                      • 1




                        The command for me was actually: python -m pip install -U pip
                        – Ev Haus
                        May 9 '15 at 17:26








                      • 4




                        You can indeed, but when running docker-compose up it raises ImportError: No module named 'fcntl'
                        – LaundroMat
                        May 14 '15 at 6:27






                      • 1




                        This solution doesn't work. The installed package is unusable (I get the same error as @LaundroMat).
                        – André Caron
                        May 19 '15 at 20:03






                      • 3




                        I was able to use docker-compose successfully using windows and Babun. Simply follow this guide to install pip and babun, and then call pip install -U docker-compose
                        – mcmil
                        May 20 '15 at 16:08






                      • 1




                        @mcmil For the record, I keep having the same problem unfortunately. (It's not that big of a problem for me, but it's of course a pity).
                        – LaundroMat
                        May 22 '15 at 8:53















                      up vote
                      6
                      down vote













                      You can install docker-compose on Windows with pip:



                      pip install -U docker-compose





                      share|improve this answer

















                      • 1




                        The command for me was actually: python -m pip install -U pip
                        – Ev Haus
                        May 9 '15 at 17:26








                      • 4




                        You can indeed, but when running docker-compose up it raises ImportError: No module named 'fcntl'
                        – LaundroMat
                        May 14 '15 at 6:27






                      • 1




                        This solution doesn't work. The installed package is unusable (I get the same error as @LaundroMat).
                        – André Caron
                        May 19 '15 at 20:03






                      • 3




                        I was able to use docker-compose successfully using windows and Babun. Simply follow this guide to install pip and babun, and then call pip install -U docker-compose
                        – mcmil
                        May 20 '15 at 16:08






                      • 1




                        @mcmil For the record, I keep having the same problem unfortunately. (It's not that big of a problem for me, but it's of course a pity).
                        – LaundroMat
                        May 22 '15 at 8:53













                      up vote
                      6
                      down vote










                      up vote
                      6
                      down vote









                      You can install docker-compose on Windows with pip:



                      pip install -U docker-compose





                      share|improve this answer












                      You can install docker-compose on Windows with pip:



                      pip install -U docker-compose






                      share|improve this answer












                      share|improve this answer



                      share|improve this answer










                      answered May 5 '15 at 18:53









                      Peter

                      969816




                      969816








                      • 1




                        The command for me was actually: python -m pip install -U pip
                        – Ev Haus
                        May 9 '15 at 17:26








                      • 4




                        You can indeed, but when running docker-compose up it raises ImportError: No module named 'fcntl'
                        – LaundroMat
                        May 14 '15 at 6:27






                      • 1




                        This solution doesn't work. The installed package is unusable (I get the same error as @LaundroMat).
                        – André Caron
                        May 19 '15 at 20:03






                      • 3




                        I was able to use docker-compose successfully using windows and Babun. Simply follow this guide to install pip and babun, and then call pip install -U docker-compose
                        – mcmil
                        May 20 '15 at 16:08






                      • 1




                        @mcmil For the record, I keep having the same problem unfortunately. (It's not that big of a problem for me, but it's of course a pity).
                        – LaundroMat
                        May 22 '15 at 8:53














                      • 1




                        The command for me was actually: python -m pip install -U pip
                        – Ev Haus
                        May 9 '15 at 17:26








                      • 4




                        You can indeed, but when running docker-compose up it raises ImportError: No module named 'fcntl'
                        – LaundroMat
                        May 14 '15 at 6:27






                      • 1




                        This solution doesn't work. The installed package is unusable (I get the same error as @LaundroMat).
                        – André Caron
                        May 19 '15 at 20:03






                      • 3




                        I was able to use docker-compose successfully using windows and Babun. Simply follow this guide to install pip and babun, and then call pip install -U docker-compose
                        – mcmil
                        May 20 '15 at 16:08






                      • 1




                        @mcmil For the record, I keep having the same problem unfortunately. (It's not that big of a problem for me, but it's of course a pity).
                        – LaundroMat
                        May 22 '15 at 8:53








                      1




                      1




                      The command for me was actually: python -m pip install -U pip
                      – Ev Haus
                      May 9 '15 at 17:26






                      The command for me was actually: python -m pip install -U pip
                      – Ev Haus
                      May 9 '15 at 17:26






                      4




                      4




                      You can indeed, but when running docker-compose up it raises ImportError: No module named 'fcntl'
                      – LaundroMat
                      May 14 '15 at 6:27




                      You can indeed, but when running docker-compose up it raises ImportError: No module named 'fcntl'
                      – LaundroMat
                      May 14 '15 at 6:27




                      1




                      1




                      This solution doesn't work. The installed package is unusable (I get the same error as @LaundroMat).
                      – André Caron
                      May 19 '15 at 20:03




                      This solution doesn't work. The installed package is unusable (I get the same error as @LaundroMat).
                      – André Caron
                      May 19 '15 at 20:03




                      3




                      3




                      I was able to use docker-compose successfully using windows and Babun. Simply follow this guide to install pip and babun, and then call pip install -U docker-compose
                      – mcmil
                      May 20 '15 at 16:08




                      I was able to use docker-compose successfully using windows and Babun. Simply follow this guide to install pip and babun, and then call pip install -U docker-compose
                      – mcmil
                      May 20 '15 at 16:08




                      1




                      1




                      @mcmil For the record, I keep having the same problem unfortunately. (It's not that big of a problem for me, but it's of course a pity).
                      – LaundroMat
                      May 22 '15 at 8:53




                      @mcmil For the record, I keep having the same problem unfortunately. (It's not that big of a problem for me, but it's of course a pity).
                      – LaundroMat
                      May 22 '15 at 8:53










                      up vote
                      5
                      down vote













                      It seems they haven't added native support into the Windows version of Boot2Docker yet.



                      So for the moment, you can use docker-compose as how you've done with fig previously: run it as a docker container.






                      share|improve this answer

















                      • 1




                        boot2docker has native support on Windows now
                        – RadiantHex
                        May 4 '15 at 0:34






                      • 1




                        alias docker-compose='docker run --rm -it -v $(pwd):/app -v /var/run/docker.sock:/var/run/docker.sock -e COMPOSE_PROJECT_NAME=$(basename $(pwd)) dduportal/docker-compose'
                        – Sowry
                        May 7 '15 at 11:31






                      • 2




                        This works for me with bash/Cygwin: alias docker-compose="docker run -v "$(pwd)":/app dduportal/docker-compose:latest"
                        – user11153
                        May 20 '15 at 13:03






                      • 1




                        Running in a container might not always work. See my edited answer below, after Ed's feedback.
                        – VonC
                        Jun 8 '15 at 15:54















                      up vote
                      5
                      down vote













                      It seems they haven't added native support into the Windows version of Boot2Docker yet.



                      So for the moment, you can use docker-compose as how you've done with fig previously: run it as a docker container.






                      share|improve this answer

















                      • 1




                        boot2docker has native support on Windows now
                        – RadiantHex
                        May 4 '15 at 0:34






                      • 1




                        alias docker-compose='docker run --rm -it -v $(pwd):/app -v /var/run/docker.sock:/var/run/docker.sock -e COMPOSE_PROJECT_NAME=$(basename $(pwd)) dduportal/docker-compose'
                        – Sowry
                        May 7 '15 at 11:31






                      • 2




                        This works for me with bash/Cygwin: alias docker-compose="docker run -v "$(pwd)":/app dduportal/docker-compose:latest"
                        – user11153
                        May 20 '15 at 13:03






                      • 1




                        Running in a container might not always work. See my edited answer below, after Ed's feedback.
                        – VonC
                        Jun 8 '15 at 15:54













                      up vote
                      5
                      down vote










                      up vote
                      5
                      down vote









                      It seems they haven't added native support into the Windows version of Boot2Docker yet.



                      So for the moment, you can use docker-compose as how you've done with fig previously: run it as a docker container.






                      share|improve this answer












                      It seems they haven't added native support into the Windows version of Boot2Docker yet.



                      So for the moment, you can use docker-compose as how you've done with fig previously: run it as a docker container.







                      share|improve this answer












                      share|improve this answer



                      share|improve this answer










                      answered Mar 30 '15 at 10:03









                      fayndee

                      1216




                      1216








                      • 1




                        boot2docker has native support on Windows now
                        – RadiantHex
                        May 4 '15 at 0:34






                      • 1




                        alias docker-compose='docker run --rm -it -v $(pwd):/app -v /var/run/docker.sock:/var/run/docker.sock -e COMPOSE_PROJECT_NAME=$(basename $(pwd)) dduportal/docker-compose'
                        – Sowry
                        May 7 '15 at 11:31






                      • 2




                        This works for me with bash/Cygwin: alias docker-compose="docker run -v "$(pwd)":/app dduportal/docker-compose:latest"
                        – user11153
                        May 20 '15 at 13:03






                      • 1




                        Running in a container might not always work. See my edited answer below, after Ed's feedback.
                        – VonC
                        Jun 8 '15 at 15:54














                      • 1




                        boot2docker has native support on Windows now
                        – RadiantHex
                        May 4 '15 at 0:34






                      • 1




                        alias docker-compose='docker run --rm -it -v $(pwd):/app -v /var/run/docker.sock:/var/run/docker.sock -e COMPOSE_PROJECT_NAME=$(basename $(pwd)) dduportal/docker-compose'
                        – Sowry
                        May 7 '15 at 11:31






                      • 2




                        This works for me with bash/Cygwin: alias docker-compose="docker run -v "$(pwd)":/app dduportal/docker-compose:latest"
                        – user11153
                        May 20 '15 at 13:03






                      • 1




                        Running in a container might not always work. See my edited answer below, after Ed's feedback.
                        – VonC
                        Jun 8 '15 at 15:54








                      1




                      1




                      boot2docker has native support on Windows now
                      – RadiantHex
                      May 4 '15 at 0:34




                      boot2docker has native support on Windows now
                      – RadiantHex
                      May 4 '15 at 0:34




                      1




                      1




                      alias docker-compose='docker run --rm -it -v $(pwd):/app -v /var/run/docker.sock:/var/run/docker.sock -e COMPOSE_PROJECT_NAME=$(basename $(pwd)) dduportal/docker-compose'
                      – Sowry
                      May 7 '15 at 11:31




                      alias docker-compose='docker run --rm -it -v $(pwd):/app -v /var/run/docker.sock:/var/run/docker.sock -e COMPOSE_PROJECT_NAME=$(basename $(pwd)) dduportal/docker-compose'
                      – Sowry
                      May 7 '15 at 11:31




                      2




                      2




                      This works for me with bash/Cygwin: alias docker-compose="docker run -v "$(pwd)":/app dduportal/docker-compose:latest"
                      – user11153
                      May 20 '15 at 13:03




                      This works for me with bash/Cygwin: alias docker-compose="docker run -v "$(pwd)":/app dduportal/docker-compose:latest"
                      – user11153
                      May 20 '15 at 13:03




                      1




                      1




                      Running in a container might not always work. See my edited answer below, after Ed's feedback.
                      – VonC
                      Jun 8 '15 at 15:54




                      Running in a container might not always work. See my edited answer below, after Ed's feedback.
                      – VonC
                      Jun 8 '15 at 15:54










                      up vote
                      5
                      down vote













                      boot2docker versions >= 1.7.0 have 64 bits userspace. This means that prebuilt binaries from their github repository are working out of the box.



                      I have used the information in VonC's answer above to write a script that downloads the latest version (or a specific version, see the commented part in the code) and persists it. It will only download the file once, but it will put it on the path on every startup of boot2docker.



                      Instructions:





                      1. boot2docker ssh from any terminal.

                      2. paste the script and press enter.


                      3. exit and then run boot2docker restart && boot2docker ssh

                      4. When the box is restarted, run docker-compose to see that it responds with its command list.


                      On Windows, the boot2docker restart command has a tendency to fail the first time. But it is just to run that command again.



                      echo 'if [ ! -f /var/lib/boot2docker/etc/docker-compose-`uname -s`-`uname -m` ]; then
                      echo "Download docker-compose..."
                      # Download latest version
                      curl -L https://github.com/docker/compose/releases/download/$(curl -s -L https://github.com/docker/compose/releases/latest |
                      grep -Eo -m 1 docker/compose/releases/tag/([0-9.]*) |
                      grep -o [0-9.]*)/docker-compose-`uname -s`-`uname -m`
                      > /var/lib/boot2docker/etc/docker-compose-`uname -s`-`uname -m`
                      # Download fixed version
                      # curl -L https://github.com/docker/compose/releases/download/1.3.1/docker-compose-`uname -s`-`uname -m`
                      # > /var/lib/boot2docker/etc/docker-compose-`uname -s`-`uname -m`
                      echo "Done!"
                      fi
                      echo "Install docker-compose on path..."
                      cp /var/lib/boot2docker/etc/docker-compose-`uname -s`-`uname -m` /usr/local/bin/docker-compose &&
                      chmod +x /usr/local/bin/docker-compose
                      echo "Done!"
                      ' | sudo tee /var/lib/boot2docker/bootlocal.sh > /dev/null &&
                      sudo chmod +x /var/lib/boot2docker/bootlocal.sh





                      share|improve this answer



















                      • 1




                        That looks great, +1
                        – VonC
                        Jul 10 '15 at 7:26















                      up vote
                      5
                      down vote













                      boot2docker versions >= 1.7.0 have 64 bits userspace. This means that prebuilt binaries from their github repository are working out of the box.



                      I have used the information in VonC's answer above to write a script that downloads the latest version (or a specific version, see the commented part in the code) and persists it. It will only download the file once, but it will put it on the path on every startup of boot2docker.



                      Instructions:





                      1. boot2docker ssh from any terminal.

                      2. paste the script and press enter.


                      3. exit and then run boot2docker restart && boot2docker ssh

                      4. When the box is restarted, run docker-compose to see that it responds with its command list.


                      On Windows, the boot2docker restart command has a tendency to fail the first time. But it is just to run that command again.



                      echo 'if [ ! -f /var/lib/boot2docker/etc/docker-compose-`uname -s`-`uname -m` ]; then
                      echo "Download docker-compose..."
                      # Download latest version
                      curl -L https://github.com/docker/compose/releases/download/$(curl -s -L https://github.com/docker/compose/releases/latest |
                      grep -Eo -m 1 docker/compose/releases/tag/([0-9.]*) |
                      grep -o [0-9.]*)/docker-compose-`uname -s`-`uname -m`
                      > /var/lib/boot2docker/etc/docker-compose-`uname -s`-`uname -m`
                      # Download fixed version
                      # curl -L https://github.com/docker/compose/releases/download/1.3.1/docker-compose-`uname -s`-`uname -m`
                      # > /var/lib/boot2docker/etc/docker-compose-`uname -s`-`uname -m`
                      echo "Done!"
                      fi
                      echo "Install docker-compose on path..."
                      cp /var/lib/boot2docker/etc/docker-compose-`uname -s`-`uname -m` /usr/local/bin/docker-compose &&
                      chmod +x /usr/local/bin/docker-compose
                      echo "Done!"
                      ' | sudo tee /var/lib/boot2docker/bootlocal.sh > /dev/null &&
                      sudo chmod +x /var/lib/boot2docker/bootlocal.sh





                      share|improve this answer



















                      • 1




                        That looks great, +1
                        – VonC
                        Jul 10 '15 at 7:26













                      up vote
                      5
                      down vote










                      up vote
                      5
                      down vote









                      boot2docker versions >= 1.7.0 have 64 bits userspace. This means that prebuilt binaries from their github repository are working out of the box.



                      I have used the information in VonC's answer above to write a script that downloads the latest version (or a specific version, see the commented part in the code) and persists it. It will only download the file once, but it will put it on the path on every startup of boot2docker.



                      Instructions:





                      1. boot2docker ssh from any terminal.

                      2. paste the script and press enter.


                      3. exit and then run boot2docker restart && boot2docker ssh

                      4. When the box is restarted, run docker-compose to see that it responds with its command list.


                      On Windows, the boot2docker restart command has a tendency to fail the first time. But it is just to run that command again.



                      echo 'if [ ! -f /var/lib/boot2docker/etc/docker-compose-`uname -s`-`uname -m` ]; then
                      echo "Download docker-compose..."
                      # Download latest version
                      curl -L https://github.com/docker/compose/releases/download/$(curl -s -L https://github.com/docker/compose/releases/latest |
                      grep -Eo -m 1 docker/compose/releases/tag/([0-9.]*) |
                      grep -o [0-9.]*)/docker-compose-`uname -s`-`uname -m`
                      > /var/lib/boot2docker/etc/docker-compose-`uname -s`-`uname -m`
                      # Download fixed version
                      # curl -L https://github.com/docker/compose/releases/download/1.3.1/docker-compose-`uname -s`-`uname -m`
                      # > /var/lib/boot2docker/etc/docker-compose-`uname -s`-`uname -m`
                      echo "Done!"
                      fi
                      echo "Install docker-compose on path..."
                      cp /var/lib/boot2docker/etc/docker-compose-`uname -s`-`uname -m` /usr/local/bin/docker-compose &&
                      chmod +x /usr/local/bin/docker-compose
                      echo "Done!"
                      ' | sudo tee /var/lib/boot2docker/bootlocal.sh > /dev/null &&
                      sudo chmod +x /var/lib/boot2docker/bootlocal.sh





                      share|improve this answer














                      boot2docker versions >= 1.7.0 have 64 bits userspace. This means that prebuilt binaries from their github repository are working out of the box.



                      I have used the information in VonC's answer above to write a script that downloads the latest version (or a specific version, see the commented part in the code) and persists it. It will only download the file once, but it will put it on the path on every startup of boot2docker.



                      Instructions:





                      1. boot2docker ssh from any terminal.

                      2. paste the script and press enter.


                      3. exit and then run boot2docker restart && boot2docker ssh

                      4. When the box is restarted, run docker-compose to see that it responds with its command list.


                      On Windows, the boot2docker restart command has a tendency to fail the first time. But it is just to run that command again.



                      echo 'if [ ! -f /var/lib/boot2docker/etc/docker-compose-`uname -s`-`uname -m` ]; then
                      echo "Download docker-compose..."
                      # Download latest version
                      curl -L https://github.com/docker/compose/releases/download/$(curl -s -L https://github.com/docker/compose/releases/latest |
                      grep -Eo -m 1 docker/compose/releases/tag/([0-9.]*) |
                      grep -o [0-9.]*)/docker-compose-`uname -s`-`uname -m`
                      > /var/lib/boot2docker/etc/docker-compose-`uname -s`-`uname -m`
                      # Download fixed version
                      # curl -L https://github.com/docker/compose/releases/download/1.3.1/docker-compose-`uname -s`-`uname -m`
                      # > /var/lib/boot2docker/etc/docker-compose-`uname -s`-`uname -m`
                      echo "Done!"
                      fi
                      echo "Install docker-compose on path..."
                      cp /var/lib/boot2docker/etc/docker-compose-`uname -s`-`uname -m` /usr/local/bin/docker-compose &&
                      chmod +x /usr/local/bin/docker-compose
                      echo "Done!"
                      ' | sudo tee /var/lib/boot2docker/bootlocal.sh > /dev/null &&
                      sudo chmod +x /var/lib/boot2docker/bootlocal.sh






                      share|improve this answer














                      share|improve this answer



                      share|improve this answer








                      edited May 23 '17 at 11:55









                      Community

                      11




                      11










                      answered Jul 10 '15 at 7:20









                      D. Josefsson

                      1,027619




                      1,027619








                      • 1




                        That looks great, +1
                        – VonC
                        Jul 10 '15 at 7:26














                      • 1




                        That looks great, +1
                        – VonC
                        Jul 10 '15 at 7:26








                      1




                      1




                      That looks great, +1
                      – VonC
                      Jul 10 '15 at 7:26




                      That looks great, +1
                      – VonC
                      Jul 10 '15 at 7:26










                      up vote
                      4
                      down vote













                      Things have progressed and lately, I've had the most success with the following method, which allows you to run it natively on Windows, by using Docker.



                      First, you'll want to install the Docker CLI for Windows:



                      curl -L https://get.docker.com/builds/Windows/x86_64/docker-latest.exe > /usr/bin/docker
                      chmod +x /usr/bin/docker


                      Next, build the docker-compose image from the Github repository:



                      docker build -t docker-compose github.com/docker/compose


                      Then, simply set up an alias to run the container:



                      alias docker-compose='docker run --rm -ti -v /var/run/docker.sock:/var/run/docker.sock -v `pwd`:`pwd` -w `pwd` docker-compose'


                      I've been using this for a while now and haven't ran into any problems -- the functionality is exactly what you'd expect as if using the binary natively, you just need to make sure your shared folders are mapped correctly into the B2D/Docker-Machine VM. I find it easiest to mirror the paths in the VM as they are on the host so my docker-compose.yml file isn't quite so confusing.






                      share|improve this answer

























                        up vote
                        4
                        down vote













                        Things have progressed and lately, I've had the most success with the following method, which allows you to run it natively on Windows, by using Docker.



                        First, you'll want to install the Docker CLI for Windows:



                        curl -L https://get.docker.com/builds/Windows/x86_64/docker-latest.exe > /usr/bin/docker
                        chmod +x /usr/bin/docker


                        Next, build the docker-compose image from the Github repository:



                        docker build -t docker-compose github.com/docker/compose


                        Then, simply set up an alias to run the container:



                        alias docker-compose='docker run --rm -ti -v /var/run/docker.sock:/var/run/docker.sock -v `pwd`:`pwd` -w `pwd` docker-compose'


                        I've been using this for a while now and haven't ran into any problems -- the functionality is exactly what you'd expect as if using the binary natively, you just need to make sure your shared folders are mapped correctly into the B2D/Docker-Machine VM. I find it easiest to mirror the paths in the VM as they are on the host so my docker-compose.yml file isn't quite so confusing.






                        share|improve this answer























                          up vote
                          4
                          down vote










                          up vote
                          4
                          down vote









                          Things have progressed and lately, I've had the most success with the following method, which allows you to run it natively on Windows, by using Docker.



                          First, you'll want to install the Docker CLI for Windows:



                          curl -L https://get.docker.com/builds/Windows/x86_64/docker-latest.exe > /usr/bin/docker
                          chmod +x /usr/bin/docker


                          Next, build the docker-compose image from the Github repository:



                          docker build -t docker-compose github.com/docker/compose


                          Then, simply set up an alias to run the container:



                          alias docker-compose='docker run --rm -ti -v /var/run/docker.sock:/var/run/docker.sock -v `pwd`:`pwd` -w `pwd` docker-compose'


                          I've been using this for a while now and haven't ran into any problems -- the functionality is exactly what you'd expect as if using the binary natively, you just need to make sure your shared folders are mapped correctly into the B2D/Docker-Machine VM. I find it easiest to mirror the paths in the VM as they are on the host so my docker-compose.yml file isn't quite so confusing.






                          share|improve this answer












                          Things have progressed and lately, I've had the most success with the following method, which allows you to run it natively on Windows, by using Docker.



                          First, you'll want to install the Docker CLI for Windows:



                          curl -L https://get.docker.com/builds/Windows/x86_64/docker-latest.exe > /usr/bin/docker
                          chmod +x /usr/bin/docker


                          Next, build the docker-compose image from the Github repository:



                          docker build -t docker-compose github.com/docker/compose


                          Then, simply set up an alias to run the container:



                          alias docker-compose='docker run --rm -ti -v /var/run/docker.sock:/var/run/docker.sock -v `pwd`:`pwd` -w `pwd` docker-compose'


                          I've been using this for a while now and haven't ran into any problems -- the functionality is exactly what you'd expect as if using the binary natively, you just need to make sure your shared folders are mapped correctly into the B2D/Docker-Machine VM. I find it easiest to mirror the paths in the VM as they are on the host so my docker-compose.yml file isn't quite so confusing.







                          share|improve this answer












                          share|improve this answer



                          share|improve this answer










                          answered Jul 13 '15 at 16:02









                          CashIsClay

                          1,3271014




                          1,3271014






















                              up vote
                              4
                              down vote













                              I got success following this issue on github




                              • install docker-machine;

                              • install python (3.4.3 worked fine)

                              • install pip;


                              • after pip... run this command to install docker-compose:



                                `pip install git+git://github.com/docker/compose.git`



                              Not believing? watch this proof






                              share|improve this answer



























                                up vote
                                4
                                down vote













                                I got success following this issue on github




                                • install docker-machine;

                                • install python (3.4.3 worked fine)

                                • install pip;


                                • after pip... run this command to install docker-compose:



                                  `pip install git+git://github.com/docker/compose.git`



                                Not believing? watch this proof






                                share|improve this answer

























                                  up vote
                                  4
                                  down vote










                                  up vote
                                  4
                                  down vote









                                  I got success following this issue on github




                                  • install docker-machine;

                                  • install python (3.4.3 worked fine)

                                  • install pip;


                                  • after pip... run this command to install docker-compose:



                                    `pip install git+git://github.com/docker/compose.git`



                                  Not believing? watch this proof






                                  share|improve this answer














                                  I got success following this issue on github




                                  • install docker-machine;

                                  • install python (3.4.3 worked fine)

                                  • install pip;


                                  • after pip... run this command to install docker-compose:



                                    `pip install git+git://github.com/docker/compose.git`



                                  Not believing? watch this proof







                                  share|improve this answer














                                  share|improve this answer



                                  share|improve this answer








                                  edited Nov 3 '15 at 20:56

























                                  answered Oct 31 '15 at 6:18









                                  Thiago Martins

                                  11114




                                  11114






















                                      up vote
                                      3
                                      down vote













                                      https://github.com/docker/compose/releases/tag/1.5.0rc3 "Compose is now available for Windows."






                                      share|improve this answer

























                                        up vote
                                        3
                                        down vote













                                        https://github.com/docker/compose/releases/tag/1.5.0rc3 "Compose is now available for Windows."






                                        share|improve this answer























                                          up vote
                                          3
                                          down vote










                                          up vote
                                          3
                                          down vote









                                          https://github.com/docker/compose/releases/tag/1.5.0rc3 "Compose is now available for Windows."






                                          share|improve this answer












                                          https://github.com/docker/compose/releases/tag/1.5.0rc3 "Compose is now available for Windows."







                                          share|improve this answer












                                          share|improve this answer



                                          share|improve this answer










                                          answered Nov 1 '15 at 18:53









                                          FDisk

                                          4,4892838




                                          4,4892838






















                                              up vote
                                              3
                                              down vote













                                              The easiest way to install Docker Compose (and Docker) on Windows, is to use the chocolatey (a package manager for Windows) package docker-compose, which should be installed after the package docker. This will free you from the many obstacles, when installing it manually and gives you an easy way to update your installation.



                                              If you´re not familiar with chocolatey, just install it - e.g. on a administrative commandline with:



                                              @powershell -NoProfile -ExecutionPolicy Bypass -Command "iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))" && SET "PATH=%PATH%;%ALLUSERSPROFILE%chocolateybin"


                                              Now that chocolatey is installed, the only thing that´s left is to fire up a administrative Powershell and do:



                                              choco install docker
                                              choco install docker-compose


                                              As a sidenote: You don´t need Boot2Docker anymore to run Docker on Windows - Docker natively support´s Windows for some time now. So no need for that anymore.






                                              share|improve this answer

























                                                up vote
                                                3
                                                down vote













                                                The easiest way to install Docker Compose (and Docker) on Windows, is to use the chocolatey (a package manager for Windows) package docker-compose, which should be installed after the package docker. This will free you from the many obstacles, when installing it manually and gives you an easy way to update your installation.



                                                If you´re not familiar with chocolatey, just install it - e.g. on a administrative commandline with:



                                                @powershell -NoProfile -ExecutionPolicy Bypass -Command "iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))" && SET "PATH=%PATH%;%ALLUSERSPROFILE%chocolateybin"


                                                Now that chocolatey is installed, the only thing that´s left is to fire up a administrative Powershell and do:



                                                choco install docker
                                                choco install docker-compose


                                                As a sidenote: You don´t need Boot2Docker anymore to run Docker on Windows - Docker natively support´s Windows for some time now. So no need for that anymore.






                                                share|improve this answer























                                                  up vote
                                                  3
                                                  down vote










                                                  up vote
                                                  3
                                                  down vote









                                                  The easiest way to install Docker Compose (and Docker) on Windows, is to use the chocolatey (a package manager for Windows) package docker-compose, which should be installed after the package docker. This will free you from the many obstacles, when installing it manually and gives you an easy way to update your installation.



                                                  If you´re not familiar with chocolatey, just install it - e.g. on a administrative commandline with:



                                                  @powershell -NoProfile -ExecutionPolicy Bypass -Command "iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))" && SET "PATH=%PATH%;%ALLUSERSPROFILE%chocolateybin"


                                                  Now that chocolatey is installed, the only thing that´s left is to fire up a administrative Powershell and do:



                                                  choco install docker
                                                  choco install docker-compose


                                                  As a sidenote: You don´t need Boot2Docker anymore to run Docker on Windows - Docker natively support´s Windows for some time now. So no need for that anymore.






                                                  share|improve this answer












                                                  The easiest way to install Docker Compose (and Docker) on Windows, is to use the chocolatey (a package manager for Windows) package docker-compose, which should be installed after the package docker. This will free you from the many obstacles, when installing it manually and gives you an easy way to update your installation.



                                                  If you´re not familiar with chocolatey, just install it - e.g. on a administrative commandline with:



                                                  @powershell -NoProfile -ExecutionPolicy Bypass -Command "iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))" && SET "PATH=%PATH%;%ALLUSERSPROFILE%chocolateybin"


                                                  Now that chocolatey is installed, the only thing that´s left is to fire up a administrative Powershell and do:



                                                  choco install docker
                                                  choco install docker-compose


                                                  As a sidenote: You don´t need Boot2Docker anymore to run Docker on Windows - Docker natively support´s Windows for some time now. So no need for that anymore.







                                                  share|improve this answer












                                                  share|improve this answer



                                                  share|improve this answer










                                                  answered May 22 '17 at 9:52









                                                  jonashackt

                                                  1,5611030




                                                  1,5611030






















                                                      up vote
                                                      2
                                                      down vote













                                                      This has been my go-to answer for getting Compose installed inside of boot2docker. If anyone would like to entertain VonC's suggestion to run Compose against their host's Docker host from within a container, I've created a journeyman developer's container that follows Compose's guidelines and is easy to install and run.



                                                      If you have a Bourne shell-like environment on Windows, you can simply run:



                                                      curl -L https://git.io/vuEqk -o /usr/local/bin/room
                                                      chmod +x /usr/local/bin/room


                                                      You can start a container on any path and take it from there by simply running:



                                                      room


                                                      You can optionally pass command arguments, so if you find yourself in a working directory that has a Compose configuration file, this would suffice to get everything up and running:



                                                      room docker-compose up


                                                      If your missing a supportive shell environment, installing one of the Git distributions for Windows which include the Git Bash prompt would suffice or you can directly use the prompts from one of either MinGW or Cygwin. If not, you can always SSH into your Docker Machine and install there.






                                                      share|improve this answer



























                                                        up vote
                                                        2
                                                        down vote













                                                        This has been my go-to answer for getting Compose installed inside of boot2docker. If anyone would like to entertain VonC's suggestion to run Compose against their host's Docker host from within a container, I've created a journeyman developer's container that follows Compose's guidelines and is easy to install and run.



                                                        If you have a Bourne shell-like environment on Windows, you can simply run:



                                                        curl -L https://git.io/vuEqk -o /usr/local/bin/room
                                                        chmod +x /usr/local/bin/room


                                                        You can start a container on any path and take it from there by simply running:



                                                        room


                                                        You can optionally pass command arguments, so if you find yourself in a working directory that has a Compose configuration file, this would suffice to get everything up and running:



                                                        room docker-compose up


                                                        If your missing a supportive shell environment, installing one of the Git distributions for Windows which include the Git Bash prompt would suffice or you can directly use the prompts from one of either MinGW or Cygwin. If not, you can always SSH into your Docker Machine and install there.






                                                        share|improve this answer

























                                                          up vote
                                                          2
                                                          down vote










                                                          up vote
                                                          2
                                                          down vote









                                                          This has been my go-to answer for getting Compose installed inside of boot2docker. If anyone would like to entertain VonC's suggestion to run Compose against their host's Docker host from within a container, I've created a journeyman developer's container that follows Compose's guidelines and is easy to install and run.



                                                          If you have a Bourne shell-like environment on Windows, you can simply run:



                                                          curl -L https://git.io/vuEqk -o /usr/local/bin/room
                                                          chmod +x /usr/local/bin/room


                                                          You can start a container on any path and take it from there by simply running:



                                                          room


                                                          You can optionally pass command arguments, so if you find yourself in a working directory that has a Compose configuration file, this would suffice to get everything up and running:



                                                          room docker-compose up


                                                          If your missing a supportive shell environment, installing one of the Git distributions for Windows which include the Git Bash prompt would suffice or you can directly use the prompts from one of either MinGW or Cygwin. If not, you can always SSH into your Docker Machine and install there.






                                                          share|improve this answer














                                                          This has been my go-to answer for getting Compose installed inside of boot2docker. If anyone would like to entertain VonC's suggestion to run Compose against their host's Docker host from within a container, I've created a journeyman developer's container that follows Compose's guidelines and is easy to install and run.



                                                          If you have a Bourne shell-like environment on Windows, you can simply run:



                                                          curl -L https://git.io/vuEqk -o /usr/local/bin/room
                                                          chmod +x /usr/local/bin/room


                                                          You can start a container on any path and take it from there by simply running:



                                                          room


                                                          You can optionally pass command arguments, so if you find yourself in a working directory that has a Compose configuration file, this would suffice to get everything up and running:



                                                          room docker-compose up


                                                          If your missing a supportive shell environment, installing one of the Git distributions for Windows which include the Git Bash prompt would suffice or you can directly use the prompts from one of either MinGW or Cygwin. If not, you can always SSH into your Docker Machine and install there.







                                                          share|improve this answer














                                                          share|improve this answer



                                                          share|improve this answer








                                                          edited Jan 6 '16 at 13:09

























                                                          answered Jan 6 '16 at 12:57









                                                          Filip Dupanović

                                                          19.3k96394




                                                          19.3k96394






























                                                               

                                                              draft saved


                                                              draft discarded



















































                                                               


                                                              draft saved


                                                              draft discarded














                                                              StackExchange.ready(
                                                              function () {
                                                              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f29289785%2fhow-to-install-docker-compose-on-windows%23new-answer', 'question_page');
                                                              }
                                                              );

                                                              Post as a guest















                                                              Required, but never shown





















































                                                              Required, but never shown














                                                              Required, but never shown












                                                              Required, but never shown







                                                              Required, but never shown

































                                                              Required, but never shown














                                                              Required, but never shown












                                                              Required, but never shown







                                                              Required, but never shown







                                                              這個網誌中的熱門文章

                                                              Hercules Kyvelos

                                                              Tangent Lines Diagram Along Smooth Curve

                                                              Yusuf al-Mu'taman ibn Hud