Docker Community Forums

Share and learn in the Docker community.

Questions about the Docker instructions to install Docker Compose

(Alastair_FM) #1

We need to download Docker Compose (DC) to use with an IBM Windows product. The IBM instructions and Docker instructions are confusing and seemingly at odds.

Issue 1 - Downloading DC

The IBM instructions give two ways to download DC; either manually from [] and then rename the file to ‘Docker-Compose.exe’ or, using the Docker instructions at [] via PowerShell.

Is there any difference between these two methods if you download the same version ? My tests would say not (same file, with the same name in the same location) but I wondering why there are two methods ?

Issue 2 - Running DC ?

The Docker instructions ,as above, say under the Windows install instructions, as step 2, to ‘Run the executable to install Docker Compose’ but the PowerShell script already renames the EXE and puts it in the [C:\Program Files\Docker] folder and DC does not appear to be an installer - just the program to be executed by Docker. When I try and run the exe in a command window I just get shown a list of arguments to supply to the DC EXE - in other words it is an actual binary rather than an installer.

I am just wondering if I am missing something or Docker have made a misprint including step 2.

Can someone comment and let me know if I am correct with the above two points ?

(Ove "Lime" Lindström) #2

how did you install docker on the targeted machine? If you install Docker Desktop for Windows ( it will include the Docker Compose binaries for you.

On Issue 1. No there is no difference between then. Basically, just doing it manually or using power shell.

If you do run your Docker Daemon on a Microsoft Windows Server 2016, then you do need to use the alternative method.

On issue 2.
The second, confusing part, of the instructions where you install docker-compose.exe is somewhat misleading. It is not a .msi or other installer but it does some writing to files it is going to need in the future and that is why you need to run it in the elevated PowerShell.

But imho, you should just install the Docker Desktop for Windows if you can.

(Alastair_FM) #3

Thanks for the prompt reply

We are installing Docker EE from the MS provider package.

You say “If you do run your Docker Daemon on a Microsoft Windows Server 2016, then you do need to use the alternative method.”

A ‘Daemon’ is the linux-speak for a Windows service. We have installer Docker EE on Win and it has installed the service which runs. Does that mean I need to use the ‘aternate method’ . Which is the ‘alternate method’ and why is it needed just because it is on WIn 2016 ?

When I ran the DC EXE in a command window it just came back with a list of the arguments I could write to it (like ‘man ls’ in Linux) and did not seem to create / generate any support files - please explain.

Will the DC EXE run differently under an elevated PowerShell prompt than an elevated command window ?


(Ove "Lime" Lindström) #4

If you can run docker-compose --versionand get docker-compose version 1.23.2, build 1110ad01 (or similar) back, then it has “installed” the command as it should. Just make sure that the docker-compose.exe is in the PATH environment variable of the server.

But… If you are installing Docker EE, why do you need docker-compose? All your stacks should then be managed inside Universal Control Plane (UCP).

(Alastair_FM) #5

We are not developing using Docker but simply running the IBM software and that states that Docker Compose is needed to be installed along with Docker EE. We are not installing the UCP.

In previous installs of the software we have simply, as IBM previously instructed, downloaded the DC EXE from Github, renamed it and put it in the ‘C:\Program Files\Docker’ folder and the software worked perfectly - we never had to run the DC EXE in order for it to setup files. In fact in the past I have done a ‘docker-compose version’ command and it has returned correctly even though we did not run the EXE.

What files / variables does running the EXE set / change ?

What difference does it make running the DC EXE in an elevated PowerShell prompt make compared to a elevated command prompt ?

Many thanks.

(Ove "Lime" Lindström) #6

I understand. The downside of abbreviations. Docker EE in my world is Docker Enterprise Edition, that includes UCP. That one, I have now learned, is only called Docker Enterprise and Docker EE is Docker Enterprise Engine in the same way that Docker Community Engine is called Docker CE.


The reason for running a PowerShell is to get access to the Cmdlets for adding modules. If you would run the Cmdlet in a command prompt, you would need to tell the command prompt to run it in PowerShell using pwsh -c Install-Module DockerMsftProvider -Force.

The actual docker-compose command doesn’t need to be in PowerShell or even elevated. When I did a test on a Azure-node running your config, I noticed that if I run docker-compose the first time without elevated permissions, I got loads of warnings about docker-compose being an “unknown program downloaded from the internet”, the same way that you get from any program not installed via the official channels. I haven’t verified it, but I make an assumption that Windows Server is adding docker-compose.exe to a Policy in the registry.

Most likely, that is what they intend with the “2. Run the executable to install Compose.” in the documentation.

(Alastair_FM) #7

Yes obviously the Docker EE program had to be installed via PowerShell because of the cmdlets and the MS packages.

I think the ‘unknown program downloaded from the internet’ warnings are from the file being automatically blocked by windows when downloaded. This is standard as you can see from

I am still not clear though what ‘files’ or ‘registry’ entries you think DC is adding when you run it because when I ran it in a command window it seemed not to run and just gave me a list of possible command arguments I could pass to the program.

Previous Docker & IBM instructions for DC (the instructions seem to have changed a few months ago) did not tell you to run the exe - just download form github, rename and put in the docker ‘C:\Progam Files\Docker’ folder.

Please can you give me a list of what files / registry items you think DC adds ?

(Ove "Lime" Lindström) #8

Lets see if I can explain this to you again.

Yes, the “unknown program” is windows default and you need to allow it at least once as an administrator/elevated permissions to make it run afterwards. docker-compose is not adding any files or registry entries (checked the code at, but Windows does. If you need to find out where Windows adds allowed programs, I suggest that you ask Microsoft.

Just running “docker-compose” will give you the help message. Docker Compose always takes a command so just “docker-compose” does nothing.

(Alastair_FM) #9

I have downloaded DC exe in the two different ways:

  • Using the PowerShell function ‘Get-hash’ to compare the two files - there are identical.

  • Looking at the file downloaded via PowerShell it does not require to be unblocked whereas the one manually downloaded does.

  • The files are exactly the same size.

Based on this and what you have said I would say a) the two files are the same b) either method is valid to source the file c) if manually downloaded the exe needs to be ‘unblocked’ d) there is nothing ‘setup’ by trying to run the exe in addition to an implicit ‘unblock’ action.

All being said and down it is best to use PowerShell as that is the most convenient but running it seems a waste of time since the program only appears to fail asking for more information.

Do you agree with me ?

Does anyone else have a view either way ?

(Ove "Lime" Lindström) #10

No, that is more or less my view on the problem to.

Good luck.