I'm relatively new to puppet, and I'm trying to create a configuration with puppet that will spit out a ready-to-go production system, like we're currently using.
I'm using Debian Jessie with Puppet 3.7.2 as both the puppet master and client. I've installed corosync from backports and now I'm trying to configure it similar to the production system with the puppetlabs-corosync module.
Q1:
My production configuration has a line:
meta target-role="Started"
on most primitives, which my new system does not have, how can I get that line in?
Example primitive:
primitive ws.client.tld_IP ocf:heartbeat:IPaddr2 \
params ip="10.0.7.30" cidr_netmask="24" nic="eth0" \
op monitor interval="120s" timeout="20s" \
meta target-role="Started"
Puppet code:
cs_primitive { 'ws.client.tld_IP':
cib => 'client',
primitive_class => 'ocf',
provided_by => 'heartbeat',
primitive_type => 'IPaddr2',
parameters => { 'ip' => '10.0.7.30', 'cidr_netmask' => '24', 'nic' => 'eth0' },
operations => { 'monitor' => { 'interval' => '120s', timeout=> '20s' } },
}
I've tried adding a "metadata" line to the primitive configuration, but I couldn't get the syntax correct, and I didn't find an example.
Q2:
I've added a line:
cib => 'client',
to every primitive, location, colocation, group as well as a cs_shadow configuration item and they're all added to that shadow cib - but not to the live cluster. How do I apply the shadow cib to the live cluster via puppet?
Q3:
How do I fix these Warnings?
Warning: Found multiple default providers for cs_shadow: crm, pcs; using crm
Warning: Found multiple default providers for cs_commit: crm, pcs; using crm
and
Warning: Puppet::Util::SUIDManager.run_and_capture is deprecated; please use Puppet::Util::Execution.execute instead.
(at /usr/lib/ruby/vendor_ruby/puppet/util/suidmanager.rb:174:in `run_and_capture')
I have a line:
provider => 'crm',
in the cs_shadow item, but the Warning doesn't vanish. Also I'm not supposed to use cs_commit directly (and I don't), so I can't add a similar line there.