Puppet Docker Clustering Docker Engines - Swarm Mode

0 votes
How can I cluster my docker engines to work in swarm mode via puppet resources?
Aug 14, 2019 in Puppet by Karan
• 19,610 points
743 views

No answer to this question. Be the first to respond.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
0 votes

To manage a cluster of Docker Engines known as a swarm, Docker Engine 1.12 includes a swarm mode.

To cluster your Docker engines, use one of the following Puppet resources:

  • Swarm manager

  • Swarm worker

Swarm manager:

  • To configure the swarm manager, add the following code to the manifest file:

docker::swarm {'cluster_manager':
  init           => true,
  advertise_addr => '192.168.1.1',
  listen_addr    => '192.168.1.1',
}
  • For a multihomed server and to enable cluster communications between the node, include the advertise_addr and listen_addr parameters.

Swarm worker

  • To configure the swarm worker, add the following code to the manifest file:

docker::swarm {'cluster_worker':
join           => true,
advertise_addr => '192.168.1.2',
listen_addr    => '192.168.1.2',
manager_ip     => '192.168.1.1',
token          => 'your_join_token'
}
  • To configure a worker node or a second manager, include the swarm manager IP address in the manager_ip parameter.

  • To define the role of the node in the cluster, include the token parameter. When creating an additional swarm manager and a worker node, separate tokens are required.

answered Aug 14, 2019 by Sirajul
• 59,230 points
Puppet+Docker: How can a user initialize, join and leave the swarm?

Related Questions In Puppet

0 votes
1 answer

Puppet+Docker: How can a user initialize, join and leave the swarm?

The docker module has an example task ...READ MORE

answered Aug 14, 2019 in Puppet by Lilly
1,069 views
0 votes
1 answer

Puppet+Docker: How do i configure a swarm if i am using windows server 2016.

There are a few considerations to be ...READ MORE

answered Aug 16, 2019 in Puppet by Sirajul
• 59,230 points
912 views
0 votes
1 answer

Is it possible to install puppet agent in a docker container on linux?

Hey @Janice, this is pretty simple. Create ...READ MORE

answered Mar 12, 2019 in Puppet by Jason
1,515 views
0 votes
1 answer

What's the need to integrate docker with puppet?

There are 3 core use cases for integrating docker with Puppet or with ...READ MORE

answered Aug 13, 2019 in Puppet by Sirajul
• 59,230 points
1,045 views
0 votes
0 answers

Docker with Puppet

I am using Puppet as a config ...READ MORE

Aug 13, 2019 in Puppet by Karan
• 19,610 points
883 views
0 votes
0 answers

How do i set up docker with puppet?

I want to use puppetlabs/docker module in ...READ MORE

Aug 13, 2019 in Puppet by Karan
• 19,610 points
2,610 views
+2 votes
1 answer
+5 votes
7 answers

Docker swarm vs kubernetes

Swarm is easy handling while kn8 is ...READ MORE

answered Aug 27, 2018 in Docker by Mahesh Ajmeria
3,924 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP