- Install Docker Machine on your Docker Client using the following documentation: https://docs.docker.com/machine/install-machine/
For the purpose of this tutorial, we leverage AmazonEC2 Driver to create Docker Host VMs on Outscale Cloud. Outscale being an Amazon EC2 API compatible Cloud provider, using this driver is very easy.
Launch the instance using the following command:
We recommend to use an Ubuntu OMI in order to make it work seamlessly with the guidelines below.
Most of the options have an equivalent with an environment variable. For more information, see Docker Machine official documentation.
Associate an External IP address (EIP) with your newly created instance as, for now, Outscale does not support automatic association of an EIP with a RunInstance API call. For more information, see Associer une EIP à une instance ou à une interface réseau.
Once the instance has been launched and SSH is available, docker-machine will provision all the elements needed to install and configure your Docker host. To view all your docker hosts, use the following command:
Point the Docker client from your instance to your Docker host using the following command:
To check your new set of environment variables, use the following command:
Run Docker containers directly in your Docker host as usual:
Do not forget to open your security groups accordingly whenever you expose your Docker Host ports. For more information, see Ajouter des règles à un security group.