Download the latest version of docker machine to /usr/local/bin folder using the following command. Curl -L /usr/local/bin/docker-machine. The docker-machine binary needs execution permissions. Apply permissions using the following command. Download Center Product Specifications. For Docker for Mac, although macOS 10.10.3 (Yosemite) or later will also meet the requirements.
Install Docker Toolbox (1.8.3 or later). You can download the latest version from here: https://www.docker.com/toolbox
There will be two quick updates to your setup. The first will be to tell your machine to not use a proxy when trying to connect to your Docker Machine (VM), and the second will be to configure your Docker Machine to use your proxy in order to connect out to the InterWebs for things like downloading images from Docker Hub.
First, add your Docker Machine VM's IP to your
no_proxy
list in ~/.bash_profile
- so your docker client can communicate with your Docker Machine without trying to go through your proxy.To get your Docker Machine's IP:
Substitute
default
for whatever the name of your Docker Machine is.Take that IP and add it to your existing no_proxy. Example if your Docker Machine IP was 192.168.99.100:
Second, configure your docker VM with your proxy settings - so your Docker Machine can communicate to the InterWebs
![Virtualbox Virtualbox](/uploads/1/1/8/9/118994200/568262248.jpg)
Now paste in your proxy settings.
Example:
Example:
Now exit out of your Docker Machine VM and restart it so the new proxy settings can take affect.
Install Docker Toolbox
You should be good to go when your VM finishes booting up, but one last proxy tip..if you wish to run Kitematic, it for some reason ignores your system proxy settings (a bug IMO), so you'll have to pass the proxy information to the application.
Alternatively, if you prefer CLI,
Docker Quickstart Terminal
should just work, and if you like to do things yourself, you can start things up manually- 1 Windows
- 2 MacOS
- 4 Alternative options
- 6 Interacting with Docker
This document contains information on how to install Dockeron your computer.
Although you can access an online Docker environment without installing anything onyour computer (see Section 4.1), you should consider this optiononly if you really cannot install Docker.
The installation procedure depends on the operating systemthat your computer runs.
The installation procedure depends on the Windows version running on your computer.
1.1 Docker Desktop for Windows
If your computer runs Windows 10 64 bits (Pro, Enterprise, or Education, build 15063 or later),you can install Docker Desktop for Windows (recommended).
Hardware prerequisites
- 64 bit processor.
- 4GB system RAM.
- BIOS-level hardware virtualization support must be enabled in the BIOS settings.For more information, see Virtualization.
VirtualBox users
Docker Toolbox Version
Docker for Windows uses Hyper-V as a virtual machine to run containers.Unfortunately, Hyper-V and VirtualBox are not compatible;when Hyper-V is enabled, VirtualBox will stop working. Download ipvanish windows.
However:
- The existing VirtualBox images will not be removed.
- When you want to use VirtualBox, you can turn Hyper-V off.
Cannot/don’t want to install Docker Desktop for for Windows
If your computer doesn’t meet the hardware requirements, or youdon’t want to install Docker Desktop for Windows because you don’t want tomess up your VirtualBox installation (although you shouldn’t really worry about the latter),you have two options:
- Install Docker Toolbox for Windows (Section 1.2).
- See the alternative options (Section 4).
Installation procedure
![Toolbox Toolbox](/uploads/1/1/8/9/118994200/663599968.jpg)
- Download Docker Desktop for Windows.
- Follow the installation instructions.You might need to restart the system to enable Hyper-V.
- Verify your installation (see Section 5).
1.2 Docker Toolbox for Windows
If your computer runs Windows 7 or higher, anddoesn’t meet the hardware requirements for Docker for Windows,you can install Docker Toolbox for Windows.
Please refer to these installation instructions.
Cannot install Docker Toolbox
- See the alternative options (Section 4).
The installation procedure depends on the version of MacOS running on your computer.
2.1 Docker Desktop for Mac.
If your computer runs MacOS 10.13 or higher, you can installDocker Desktop for Mac (recommended).
Hardware requirements
- Your computer hardware must be a 2010 or a newer model.Verify that your computer is compatible withDocker Desktop for Mac:
- Open a terminal.
- Run the following command:
sysctl kern.hv_support
. - If the output of the command is
kern.hv_support: 1
your computer is compatible.
- At least 4GB of RAM.
VirtualBox users
If you have a version of VirtualBox older than 4.3.30, you should consider upgrading it, asit would not be compatible with Docker Desktop.
Cannot install Docker Desktop for Mac
If your computer doesn’t meet the hardware requirements,you have two options:
- Install Docker Toolbox for Mac (Section 2.2).
- See the alternative options (Section 4).
Installation instructions
- Download Docker Desktop for Mac.
- Follow the installation instructions.
- Verify your installation (see Section 5).
2.2 Docker Toolbox for Mac
If your computer runs MacOs 10.8 or higher, anddoesn’t meet the hardware requirements for Docker Desktop for Mac,you can install Docker Toolbox for Mac.
Please refer to these installation instructions.
Cannot install Docker Toolbox
- See the alternative options (Section 4).
You can install Docker on the following Linux distributions:
- CentOS (installation instructions).
- Debian (installation instructions).
- Fedora (installation instructions).
- Ubuntu (installation instructions).
Make sure to read the post-installation steps for Linuxand to take the necessary steps to be able to run Docker as a non-root user.
If you’re unable to install Docker on your computer,you have two options left:using the Docker playground or installing Docker in a Linux virtual machine.
4.1 Docker playground
The Docker playground isan online Docker environment that you can play with for free.
- The advantage is that you don’t have anything to install on your computer.
- The disadvantage is that you might be unable to open a sessiondepending on the number of active sessions.
In order to connect to the playground,you need to create an account on DockerHub.
4.2 Docker in an already prepared virtual machine
We provide an Alpine Linux virtual machine with Docker alreadyinstalled (size: 743MB).The virtual machine will give you a simple command-line interfacewhere you can type the Docker commands.
Download the virtual machineand import it into VirtualBox, as shown in the following video(Safari users: watch on YouTube for fullscreen mode;all users: select HD quality for a better experience).
The username and password to log into the virtual machine are both root.In the video, you’ll be directed to create afolder in your computer called docker_files.There,you’ll place all files that you’ll need to play with Docker.Don’t hesitate to create subdirectories to organize your files(e.g., td-1, final-project).You’ll be able to access this folder from the virtual machinefrom the folder /mnt/docker_files.This way, you can manipulate your files by usingthe file system manager of your computer and you’ll just use theterminal of the virtual machine to type the Docker commands.
4.3 Docker in a Ubuntu Linux virtual machine
- Install VirtualBox on your computer.
- Download the ISO image of Ubuntu Desktop.
- Open VirtualBox and select New to install a new operating system.
- Choose Linux as the operating system type and Ubuntu (64-bit) as the version.
- Set the memory size (1024 MB or higher).
- Create a virtual hard disk with the recommended size.
- Select VDI (VirtualBox Disk Image) as the hard disk type.
- Select the option Fixed size and create the new virtual machine.
- Double-click on the new virtual machine and, when prompted,select the ISO image of Ubuntu.
- Follow the instructions to install Ubuntu.
- When Ubuntu is finally installed, follow the instructions in Section 3 toinstall Docker in Ubuntu.
Open a terminal and type the following command:
If everything is OK, you should see the output in the following figure.
In this course, we’ll learn how to interact with the Docker engineby using the command-line terminal.This option might seem a bit tedious(nobody likes to remember textual commands), but it offersa great flexibility.
This is the option that we recommend and for which we’ll providea full support throughout the course.
6.1 Graphical interface
If you really want to use a graphical interface, you might want to look atPortainer, which isitself run as a Docker container.
Open a terminal and copy and paste the following commands:
Windows users
Open a terminal and copy and paste the following commands:What Is Docker Toolbox
- When the container is up and running,the interface is available at the following URL:http://localhost:9000.
- Choose a password and create the user admin.
- Select Local to manage the Docker environment installed on your computer andclick on Connect.
- Click on the endpoint Local (figure below) to access the dashboard.
- The menu on the left of the dashboard allows you to managethe different components of your Docker environment (e.g., containers, images, volumes and networks).
A user guide of Portainer is very much out of the scope of this course.However, the interface is rather intuitive and you should easily find outhow to create, run, stop and remove containers, build images andcreate volumes and networks.
Docker Toolbox For Linux
In this section we’ll document the installation issuesthat you might experience.
Don’t hesitate to contact usto report your installation problems.