Deploying Docker Containers with Puppet

You are viewing an old version of this article. View the current version here.

Puppet can also be used to administer Docker containers.

In this page you will find some examples. All the examples use the docker resource type, supported by the Puppet company.

How to Install and Upgrade Docker with Puppet

Installing or upgrading Docker is simple:

class { 'docker':
  use_upstream_package_source => false,
  version => '17.09.0~ce-0~debian',
}

In this example we are using our system's repositories instead of Docker official repositories, and we are specifying the desired version. To upgrade Docker later, all we need to do is to modify the version number. While specifying a version is not mandatory, it is a good idea because it makes our manifest more reproducible.

Check the docker resource type documentation to find out how to use more features: for example you can use Docker Enterprise Edition, or bind the Docker daemon to a TCP port.

How to Deploy a Container with Puppet

References


Content initially contributed by Vettabase Ltd.

Comments

Comments loading...
Content reproduced on this site is the property of its respective owners, and this content is not reviewed in advance by MariaDB. The views, information and opinions expressed by this content do not necessarily represent those of MariaDB or any other party.