Setup Container tutorial#
Setup environment#
First let's create a dedicated folder for this tutorial:
mkdir -p ~/containers-training/containers
cd ~/containers-training/containers
Installing Docker#
Installing Docker (specifically Docker Desktop) is quite straightforward on Mac, Windows and Linux distributions. Note that Docker runs as root, which means that you have to have sudo
privileges on your computer in order to install or run Docker. When you have finished installing docker, regardless of which OS you are on, please type docker --version
to verify that the installation was successful.
Docker for older versions of OSX/Windows
The latest version of Docker may not work if you have an old version of either OSX or Windows. You can find older Docker versions that may be compatible for you if you go to https://docs.docker.com/desktop/ and click "Previous versions" in the left side menu.
MacOS#
Go to mac-install section of the Docker documentation and select the download option that is suitable for your computer’s architecture (i.e. if you have an Intel chip or a Apple silicon chip). This will download a dmg
file - click on it when it’s done to start the installation. This will open up a window where you can drag the Docker.app to Applications. Close the window and click the Docker app from the Applications menu. Now it’s basically just to click “next” a couple of times and we should be good to go. You can find the Docker icon in the menu bar in the upper right part of the screen.
Linux#
Go to the linux-install section of the Docker documentation and make sure that your computer meets the system requirements. There you can also find instructions for different Linux distributions in the left sidebar.
Windows#
Go to the windows-install section of the Docker documentation and select the download option that is suitable for your computer’s architecture (i.e. if you have an Intel chip (x86) or ARM). Once the download is complete, execute the file and follow the instructions. You can now start Docker from the Start menu. You can search for it if you cannot find it; the Docker whale icon should appear in the task bar.
You will probably need to enable integration with the Linux subsystem, if you haven’t done so during the installation of Docker Desktop. Right-click on the Docker whale icon in the task bar and select Settings. Choose Resources and select WPS integration. Enable integration with the Linux subsystem and click Apply & Restart; also restart the Linux subsystem.