Installing Docker for Windows

The installation is quite simple: once you have downloaded the installer (https://docs.docker.com/docker-for-windows/install/), just run it and you're done. The installation process is generally very linear. The only thing that needs attention is the final phase of the installation, in which it might be required to enable Hyper-V features. If so, then we accept and restart the machine.

Once the computer is restarted, the Docker icon should appear in the system tray in the bottom right of the screen.

Open Command Prompt or the PowerShell console and check whether everything is okay by executing the docker version command:

C:>docker version
Client: Docker Engine - Community
Version: 18.09.2
API version: 1.39
Go version: go1.10.8
Git commit: 6247962
Built: Sun Feb 10 04:12:31 2019
OS/Arch: windows/amd64
Experimental: false

Server: Docker Engine - Community
Engine:
Version: 18.09.2
API version: 1.39 (minimum version 1.12)
Go version: go1.10.6
Git commit: 6247962
Built: Sun Feb 10 04:13:06 2019
OS/Arch: linux/amd64
Experimental: false

The most interesting part of the output is the subdivision that is made between the client and the server. The client is our local Windows system, while the server is the Linux virtual machine that Docker instantiated behind the scenes. The parts communicate with each other thanks to the API layer, as mentioned in the introduction of this recipe.

Now, let's see how to containerize (or dockerize) a simple Python application.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset