In-house patch to touch /var/lib/rabbitmq/.erlang.cookie with the
proper ownership before starting rabbitmq. This patch is not suitable
for upstream.
--- puppetlabs-rabbitmq-5.3.1/manifests/init.pp.orig 2016-04-21 06:25:00.840836012 -0700
+++ puppetlabs-rabbitmq-5.3.1/manifests/init.pp 2016-04-21 06:25:36.238696524 -0700
@@ -1,3 +1,7 @@
+#######################################################################
+# Oracle has modified the originally distributed contents of this file.
+#######################################################################
+
# Main rabbitmq class
class rabbitmq(
$admin_enable = $rabbitmq::params::admin_enable,
@@ -233,7 +237,13 @@
anchor { 'rabbitmq::begin': }
anchor { 'rabbitmq::end': }
- Anchor['rabbitmq::begin'] -> Class['::rabbitmq::install']
+ file { 'cookie_owner':
+ path => '/var/lib/rabbitmq/.erlang.cookie',
+ owner => 'rabbitmq',
+ group => 'daemon',
+ }
+
+ Anchor['rabbitmq::begin'] -> Class['::rabbitmq::install'] -> File['cookie_owner']
-> Class['::rabbitmq::config'] ~> Class['::rabbitmq::service']
-> Class['::rabbitmq::management'] -> Anchor['rabbitmq::end']