Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Docker on Windows Server 2019 for linux and windows containers

POWERSHELL: (Admin)

Install-WindowsFeature Hyper-V
Install-WindowsFeature Containers

mkdir "$Env:ProgramFiles\Docker"

cd "$Env:ProgramFiles\Docker"

Invoke-WebRequest -UseBasicParsing -OutFile dockerd.exe 
https://master.dockerproject.org/windows/x86_64/dockerd.exe

Invoke-WebRequest -UseBasicParsing -OutFile docker.exe https://master.dockerproject.org/windows/x86_64/docker.exe

cd ~\

Invoke-WebRequest -UseBasicParsing -OutFile release.zip https://github.com/linuxkit/lcow/releases/tag/v4.14.35-v0.3.9

Expand-Archive release.zip -DestinationPath "$Env:ProgramFiles\Linux Containers\."
rm release.zip

CMD.exe (Admin)

sc create Docker binpath= "\"C:\Program Files\Docker\dockerd.exe\" --run-service --experimental" start= delayed-auto
sc start Docker
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment