diff --git a/deployment/puppet/mcollective/manifests/server.pp b/deployment/puppet/mcollective/manifests/server.pp index 97ad82af7e..98e8568f1c 100644 --- a/deployment/puppet/mcollective/manifests/server.pp +++ b/deployment/puppet/mcollective/manifests/server.pp @@ -55,6 +55,7 @@ class mcollective::server( group => root, mode => 0600, require => Package[$mcollective_package], + notify => Service['mcollective'], } service { "mcollective": diff --git a/deployment/puppet/mcollective/templates/server.cfg.erb b/deployment/puppet/mcollective/templates/server.cfg.erb index 2b640c125c..0220b6517d 100644 --- a/deployment/puppet/mcollective/templates/server.cfg.erb +++ b/deployment/puppet/mcollective/templates/server.cfg.erb @@ -31,6 +31,7 @@ plugin.rabbitmq.pool.1.host = <%= @host %> plugin.rabbitmq.pool.1.port = <%= @stompport %> plugin.rabbitmq.pool.1.user = <%= @user %> plugin.rabbitmq.pool.1.password = <%= @password %> +plugin.rabbitmq.heartbeat_interval = 30 <% end -%> # Facts diff --git a/deployment/puppet/nailgun/manifests/init.pp b/deployment/puppet/nailgun/manifests/init.pp index 6fab49fd42..e43c477e37 100644 --- a/deployment/puppet/nailgun/manifests/init.pp +++ b/deployment/puppet/nailgun/manifests/init.pp @@ -60,6 +60,7 @@ class nailgun( Class["nailgun::user"] -> Class["nailgun::logrotate"] -> Class["nailgun::rabbitmq"] -> + Class["nailgun::mcollective"] -> Class["nailgun::venv"] -> Class["nailgun::astute"] -> Class["nailgun::nginx-nailgun"] -> diff --git a/deployment/puppet/nailgun/manifests/mcollective.pp b/deployment/puppet/nailgun/manifests/mcollective.pp index 7d3ccedafa..f67dab6c56 100644 --- a/deployment/puppet/nailgun/manifests/mcollective.pp +++ b/deployment/puppet/nailgun/manifests/mcollective.pp @@ -7,6 +7,7 @@ class nailgun::mcollective( $rabbitmq_host = "localhost", ){ + anchor { 'nailgun::mcollective start' :} -> class { "mcollective::client": pskey => $mco_pskey, vhost => $mco_vhost, @@ -14,7 +15,7 @@ class nailgun::mcollective( password => $mco_password, host => $rabbitmq_host, stomp => false, - } + } -> class { "mcollective::server": pskey => $mco_pskey, vhost => $mco_vhost, @@ -22,6 +23,7 @@ class nailgun::mcollective( password => $mco_password, host => $rabbitmq_host, stomp => false, - } - + } -> + anchor { 'nailgun::mcollective end' :} + } diff --git a/deployment/puppet/nailgun/manifests/rabbitmq.pp b/deployment/puppet/nailgun/manifests/rabbitmq.pp index 11370003e0..ccbcfc9999 100644 --- a/deployment/puppet/nailgun/manifests/rabbitmq.pp +++ b/deployment/puppet/nailgun/manifests/rabbitmq.pp @@ -11,6 +11,10 @@ class nailgun::rabbitmq ( $rabbitmq_host = "localhost", ) { + include stdlib + anchor { 'nailgun::rabbitmq start' :} + anchor { 'nailgun::rabbitmq end' :} + define access_to_rabbitmq_port ($port, $protocol = 'tcp') { $rule = "-p $protocol -m state --state NEW -m $protocol --dport $port -j ACCEPT" @@ -125,4 +129,9 @@ class nailgun::rabbitmq ( stomp_port => $stompport, node_ip_address => 'UNSET', } + + Anchor['nailgun::rabbitmq start'] -> + Class['rabbitmq::server'] -> + Anchor['nailgun::rabbitmq end'] + }