Docker & Container Runtimes, Mint

How to install Docker Machine on Linux Mint 18 and 18.1

If you’ve read and made use of this article to install Docker on Linux Mint 18 or 18.1, this is the next article in line.

While installing Docker makes it possible to run Docker containers locally on your machine, installing Docker Machine makes it possible to provision servers locally and remotely on supported Cloud service providers like DigitalOcean and AWS with Docker (Engine) pre-installed. Such servers are called Dockerized hosts or managed machines.

So in this article, you’ll learn how to install Docker Machine on Linux Mint 18 or 18.1, with an eye towards using it to provision such machines.

Download and Install Docker Machine

Installing Docker Machine involves downloading its binary to your computer, copying it to the appropriate directory and making it executable. The commands required to get all that done are given in this code block. Note that at the time of this publication, Docker Machine 0.8.2 is the latest, stable release. The development branch is at v0.9.0 RC2. You might want to keep track of the very latest release here.

Install Extra Bash Scripts

With Docker Machine installed, there are three additional Bash scripts needed to be installed that will make using the docker-machine command a bit easier. The scripts, and the functionality they bring to the table, are:

  • docker-machine.bash: This provides command completion for commands, machine names and filepaths
  • docker-machine-prompt.bash: This makes it possible to see the active machine in your shell prompt
  • docker-machine-wrapper.bash: This adds a docker-machine use subcommand to switch the active machine
Related Post:  Create a bootable USB stick of Linux Mint 17.3 on a Windows 10 PC

The three Bash scripts will need to be linked to the /etc/bash_completion.d directory. The following commands shows how to link all three scripts:

That last file – docker-machine-prompt.bash – requires additional configuration. You need to modify the PS1 environment variable so that it would function correctly. The PS1 environment variable you need to modify is in the .bashrc file under your home directory. Use the follow commands to modify it.

Related Post:  How to provision Dockerized hosts with Docker Machine from Linux Mint 18, 18.1

That’s all you need to do to install Docker Machine on Linux Mint 18 and 18.1. The next step is to start provisioning Dockerized hosts (machines) with it. That will be the subject of the next article, which will be published latest Friday, December 16 (2016).

If you need to look at the code for the three Bash scripts, you’ll find them here. For more information on Docker Machine, click here.

Docker on Linux Mint 18

LinuxBSDos needs your donation to continue!

I hope this article has saved you valuable time and effort to fix a problem that would have taken more time than is necessary. That makes me happy, and why I love doing this. But because more people than ever are reading articles like this with an adblocker, ad revenues have fallen to a level that's not enough to cover my operating costs. That's why I want to ask you a favor: To make a one-time or recurring donation to support this site and keep it going. It's a small favor, but every one counts. And you can make your donation using Patreon or directly via Paypal. Thank you for whatever donation you're able to make.

Donate via Patreon. Donate via Paypal.

Aside from donation, you may also signup to receive an email once I publish new content. Your email will not be shared or traded to anyone. And you can unsubscribe at any time.

Please share:

We Recommend These Vendors and Free Offers

Launch an SSD VPS in Europe, USA, Asia & Australia on Vultr's KVM-based Cloud platform starting at $5:00/month (15 GB SSD, 768 MB of RAM).

Deploy an SSD Cloud server in 55 seconds on DigitalOcean. Built for developers and starting at $5:00/month (20 GB SSD, 512 MB of RAM).

Want to become an expert ethical hacker and penetration tester? Request your free video training course of Online Penetration Testing and Ethical Hacking

Whether you're new to Linux or are a Linux guru, you can learn a lot more about the Linux kernel by requesting your free ebook of Linux Kernel In A Nutshell.


Leave a Comment

Your email address will not be published. Required fields are marked *

*