In this article, I’ll show you how to deploy Windows Containers on Windows Server 2016 with the Docker Engine management tool.
Windows Containers was first released with Windows Server 2016 and it was In the making for a few years before the release.
The management tool for Windows Containers Is Docker Engine which offers a set of commands that allows us to manage, create and delete Containers.
Windows Containers has two components, The first Is the Windows Containers Server role and the 2nd Is the Docker Engine for Windows Server which both are Installed during the Installation steps below.
Microsoft has managed to streamline the Installation of the two components using a set of a few PowerShell cmdlets.
To Install Docker for Windows on a Windows Server 2016 open a PowerShell console and type the cmdlet below (you will need Internet access from the server to download Docker Engine PowerShell Module).
Install-Module -Name DockerMsftProvider -Repository PSGallery -Force
Next, run the cmdlet below to Install the Docker PowerShell Provider:
Install-Package -Name docker -ProviderName DockerMsftProvider
Once done, Restart the Sever.
To check the Installed docker version type:
To test If the Installation was successful, I’ll download a sample Container Image and run a new Windows Container.
First I’ll import the module using the cmdlet:
To run the sample Dotnet container, I’ll use the command below to download and run the Dot Net Sample Container
docker run microsoft/dotnet-samples:dotnetapp-nanoserver
As you can see below my Windows Container Is running.