diff options
Diffstat (limited to 'manifests/profile/pacemaker/neutron')
-rw-r--r-- | manifests/profile/pacemaker/neutron/dhcp.pp | 5 | ||||
-rw-r--r-- | manifests/profile/pacemaker/neutron/l3.pp | 5 | ||||
-rw-r--r-- | manifests/profile/pacemaker/neutron/metadata.pp | 5 | ||||
-rw-r--r-- | manifests/profile/pacemaker/neutron/ml2.pp | 15 | ||||
-rw-r--r-- | manifests/profile/pacemaker/neutron/ovs.pp | 6 | ||||
-rw-r--r-- | manifests/profile/pacemaker/neutron/server.pp | 37 |
6 files changed, 31 insertions, 42 deletions
diff --git a/manifests/profile/pacemaker/neutron/dhcp.pp b/manifests/profile/pacemaker/neutron/dhcp.pp index 841d225..1f3b178 100644 --- a/manifests/profile/pacemaker/neutron/dhcp.pp +++ b/manifests/profile/pacemaker/neutron/dhcp.pp @@ -34,11 +34,8 @@ class tripleo::profile::pacemaker::neutron::dhcp ( include ::neutron::params include ::tripleo::profile::pacemaker::neutron + include ::tripleo::profile::base::neutron::dhcp - class { '::tripleo::profile::base::neutron::dhcp': - manage_service => false, - enabled => false, - } if $step >= 5 and downcase($::hostname) == $pacemaker_master { pacemaker::resource::service { $::neutron::params::dhcp_agent_service: clone_params => 'interleave=true', diff --git a/manifests/profile/pacemaker/neutron/l3.pp b/manifests/profile/pacemaker/neutron/l3.pp index a900016..e1699cc 100644 --- a/manifests/profile/pacemaker/neutron/l3.pp +++ b/manifests/profile/pacemaker/neutron/l3.pp @@ -34,11 +34,8 @@ class tripleo::profile::pacemaker::neutron::l3 ( include ::neutron::params include ::tripleo::profile::pacemaker::neutron + include ::tripleo::profile::base::neutron::l3 - class { '::tripleo::profile::base::neutron::l3': - manage_service => false, - enabled => false, - } if $step >= 5 and downcase($::hostname) == $pacemaker_master { pacemaker::resource::service { $::neutron::params::l3_agent_service: clone_params => 'interleave=true', diff --git a/manifests/profile/pacemaker/neutron/metadata.pp b/manifests/profile/pacemaker/neutron/metadata.pp index 4030bb2..e6bccb1 100644 --- a/manifests/profile/pacemaker/neutron/metadata.pp +++ b/manifests/profile/pacemaker/neutron/metadata.pp @@ -34,11 +34,8 @@ class tripleo::profile::pacemaker::neutron::metadata ( include ::neutron::params include ::tripleo::profile::pacemaker::neutron + include ::tripleo::profile::base::neutron::metadata - class { '::tripleo::profile::base::neutron::metadata': - manage_service => false, - enabled => false, - } if $step >= 5 and downcase($::hostname) == $pacemaker_master { pacemaker::resource::service { $::neutron::params::metadata_agent_service: clone_params => 'interleave=true', diff --git a/manifests/profile/pacemaker/neutron/ml2.pp b/manifests/profile/pacemaker/neutron/ml2.pp index 6c6e580..8acaf21 100644 --- a/manifests/profile/pacemaker/neutron/ml2.pp +++ b/manifests/profile/pacemaker/neutron/ml2.pp @@ -18,8 +18,19 @@ # # === Parameters # -class tripleo::profile::pacemaker::neutron::ml2 { +# [*pacemaker_master*] +# (Optional) The hostname of the pacemaker master +# Defaults to hiera('bootstrap_nodeid') +# +class tripleo::profile::pacemaker::neutron::ml2 ( + $pacemaker_master = hiera('bootstrap_nodeid'), +) { + include ::neutron::params include ::tripleo::profile::pacemaker::neutron - include ::tripleo::profile::base::neutron::ml2 + + class { '::tripleo::profile::base::neutron::ml2': + sync_db => ($::hostname == downcase($pacemaker_master)) + } + } diff --git a/manifests/profile/pacemaker/neutron/ovs.pp b/manifests/profile/pacemaker/neutron/ovs.pp index c3ce36e..34ff5d3 100644 --- a/manifests/profile/pacemaker/neutron/ovs.pp +++ b/manifests/profile/pacemaker/neutron/ovs.pp @@ -34,11 +34,7 @@ class tripleo::profile::pacemaker::neutron::ovs ( include ::neutron::params include ::tripleo::profile::pacemaker::neutron - - class { '::tripleo::profile::base::neutron::ovs': - manage_service => false, - enabled => false, - } + include ::tripleo::profile::base::neutron::ovs if $step >= 5 and downcase($::hostname) == $pacemaker_master { diff --git a/manifests/profile/pacemaker/neutron/server.pp b/manifests/profile/pacemaker/neutron/server.pp index 4ff2e88..0bad1b9 100644 --- a/manifests/profile/pacemaker/neutron/server.pp +++ b/manifests/profile/pacemaker/neutron/server.pp @@ -23,36 +23,27 @@ # Defaults to hiera('bootstrap_nodeid') # # [*step*] -# (Optional) The current step in deployment. See tripleo-heat-templates -# for more details. -# Defaults to hiera('step') +# (Optional) The current step in deployment. See tripleo-heat-templates +# for more details. +# Defaults to hiera('step') # class tripleo::profile::pacemaker::neutron::server ( $pacemaker_master = hiera('bootstrap_nodeid'), - $step = hiera('step'), + $step = hiera('step'), ) { + include ::neutron::params include ::tripleo::profile::pacemaker::neutron - if $step >= 5 { - - class { '::tripleo::profile::base::neutron::server': - sync_db => ($::hostname == downcase($pacemaker_master)), - manage_service => false, - enabled => false, - } - - if ($::hostname == downcase($pacemaker_master)) { - pacemaker::constraint::base { 'keystone-to-neutron-server-constraint': - constraint_type => 'order', - first_resource => 'openstack-core-clone', - second_resource => "${::neutron::params::server_service}-clone", - first_action => 'start', - second_action => 'start', - require => [Pacemaker::Resource::Ocf['openstack-core'], - Pacemaker::Resource::Service[$::neutron::params::server_service]], - } - } + $sync_db = ($::hostname == downcase($pacemaker_master)) + if $step >= 2 and $sync_db { + include ::neutron::db::mysql + Exec<| title == 'galera-ready'|> -> Class['neutron::db::mysql'] + } + if $step >= 4 or ( $step >= 3 and $sync_db ) { + include ::neutron::server::notifications + include ::neutron::server } + } |