diff options
Diffstat (limited to 'manifests/profile/base/neutron/plugins/ml2.pp')
-rw-r--r-- | manifests/profile/base/neutron/plugins/ml2.pp | 23 |
1 files changed, 14 insertions, 9 deletions
diff --git a/manifests/profile/base/neutron/plugins/ml2.pp b/manifests/profile/base/neutron/plugins/ml2.pp index b462e1b..c89bc02 100644 --- a/manifests/profile/base/neutron/plugins/ml2.pp +++ b/manifests/profile/base/neutron/plugins/ml2.pp @@ -18,28 +18,34 @@ # # === Parameters # +# [*bootstrap_node*] +# (Optional) The hostname of the node responsible for bootstrapping tasks +# Defaults to hiera('bootstrap_nodeid') +# # [*mechanism_drivers*] # (Optional) The mechanism drivers to use with the Ml2 plugin # Defaults to hiera('neutron::plugins::ml2::mechanism_drivers') # -# [*sync_db*] -# (Optional) Whether to run Neutron DB sync operations -# Defaults to undef -# # [*step*] # (Optional) The current step in deployment. See tripleo-heat-templates # for more details. # Defaults to hiera('step') # class tripleo::profile::base::neutron::plugins::ml2 ( - $mechanism_drivers = hiera('neutron::plugins::ml2::mechanism_drivers'), - $sync_db = true, - $step = hiera('step'), + $bootstrap_node = hiera('bootstrap_nodeid', undef), + $mechanism_drivers = hiera('neutron::plugins::ml2::mechanism_drivers'), + $step = hiera('step'), ) { + if $::hostname == downcase($bootstrap_node) { + $sync_db = true + } else { + $sync_db = false + } + + include ::tripleo::profile::base::neutron if $step >= 4 or ( $step >= 3 and $sync_db ) { include ::neutron::plugins::ml2 - include ::tripleo::profile::base::neutron if 'cisco_n1kv' in $mechanism_drivers { include ::tripleo::profile::base::neutron::n1k @@ -56,7 +62,6 @@ class tripleo::profile::base::neutron::plugins::ml2 ( if 'bsn_ml2' in $mechanism_drivers { include ::neutron::plugins::ml2::bigswitch::restproxy - include ::neutron::agents::bigswitch } } } |