Use rabbitmq ipv6 flag
authorJohn Eckersberg <jeckersb@redhat.com>
Mon, 26 Jun 2017 21:11:50 +0000 (17:11 -0400)
committerMichele Baldessari <michele@acksyn.org>
Mon, 14 Aug 2017 15:25:10 +0000 (17:25 +0200)
The internal details of enabling IPv6 have moved upstream[1], so just
set the ipv6 flag when desired and don't worry about the details
anymore!

[1] https://github.com/puppetlabs/puppetlabs-rabbitmq/pull/552

Closes-Bug: #1710658

Change-Id: Ib22507c4d02f0fae5c0189ab7e040efac3df7e2f

manifests/profile/base/rabbitmq.pp

index d0b4a05..fbe5113 100644 (file)
@@ -98,15 +98,6 @@ class tripleo::profile::base::rabbitmq (
     $tls_keyfile = undef
   }
 
-  # IPv6 environment, necessary for RabbitMQ.
-  if $ipv6 {
-    $rabbit_env = merge($environment, {
-      'RABBITMQ_SERVER_START_ARGS' => '"-proto_dist inet6_tcp"',
-      'RABBITMQ_CTL_ERL_ARGS' => '"-proto_dist inet6_tcp"'
-    })
-  } else {
-    $rabbit_env = $environment
-  }
   if $inet_dist_interface {
     $real_kernel_variables = merge(
       $kernel_variables,
@@ -125,10 +116,11 @@ class tripleo::profile::base::rabbitmq (
         cluster_nodes           => $nodes,
         config_kernel_variables => $real_kernel_variables,
         config_variables        => $config_variables,
-        environment_variables   => $rabbit_env,
+        environment_variables   => $environment,
         # TLS options
         ssl_cert                => $tls_certfile,
         ssl_key                 => $tls_keyfile,
+        ipv6                    => $ipv6,
       }
       # when running multi-nodes without Pacemaker
       if $manage_service {
@@ -144,10 +136,11 @@ class tripleo::profile::base::rabbitmq (
       class { '::rabbitmq':
         config_kernel_variables => $kernel_variables,
         config_variables        => $config_variables,
-        environment_variables   => $rabbit_env,
+        environment_variables   => $environment,
         # TLS options
         ssl_cert                => $tls_certfile,
         ssl_key                 => $tls_keyfile,
+        ipv6                    => $ipv6,
       }
     }
   }