aboutsummaryrefslogtreecommitdiffstats
path: root/manifests/profile/base/neutron
diff options
context:
space:
mode:
Diffstat (limited to 'manifests/profile/base/neutron')
-rw-r--r--manifests/profile/base/neutron/l2gw.pp37
-rw-r--r--manifests/profile/base/neutron/opendaylight.pp30
-rw-r--r--manifests/profile/base/neutron/plugins/ml2/opendaylight.pp9
-rw-r--r--manifests/profile/base/neutron/plugins/ovs/opendaylight.pp14
-rw-r--r--manifests/profile/base/neutron/server.pp13
5 files changed, 75 insertions, 28 deletions
diff --git a/manifests/profile/base/neutron/l2gw.pp b/manifests/profile/base/neutron/l2gw.pp
new file mode 100644
index 0000000..da71108
--- /dev/null
+++ b/manifests/profile/base/neutron/l2gw.pp
@@ -0,0 +1,37 @@
+#
+# Copyright (C) 2017 Red Hat Inc.
+#
+# Author: Peng Liu <pliu@redhat.com>
+#
+# Licensed under the Apache License, Version 2.0 (the "License"); you may
+# not use this file except in compliance with the License. You may obtain
+# a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
+# License for the specific language governing permissions and limitations
+# under the License.
+#
+# == Class: tripleo::profile::base::neutron::l2gw
+#
+# Neutron L2 Gateway Service plugin profile for TripleO
+#
+# === Parameters
+#
+# [*step*]
+# (Optional) The current step in deployment. See tripleo-heat-templates
+# for more details.
+# Defaults to hiera('step')
+#
+class tripleo::profile::base::neutron::l2gw (
+ $step = hiera('step'),
+) {
+ include ::tripleo::profile::base::neutron
+
+ if $step >= 4 {
+ include ::neutron::services::l2gw
+ }
+}
diff --git a/manifests/profile/base/neutron/opendaylight.pp b/manifests/profile/base/neutron/opendaylight.pp
index 556fe63..b5e6d11 100644
--- a/manifests/profile/base/neutron/opendaylight.pp
+++ b/manifests/profile/base/neutron/opendaylight.pp
@@ -22,19 +22,35 @@
# (Optional) The current step of the deployment
# Defaults to hiera('step')
#
-# [*primary_node*]
-# (Optional) The hostname of the first node of this role type
-# Defaults to hiera('bootstrap_nodeid', undef)
+# [*odl_api_ips*]
+# (Optional) List of OpenStack Controller IPs for ODL API
+# Defaults to hiera('opendaylight_api_node_ips')
+#
+# [*node_name*]
+# (Optional) The short hostname of node
+# Defaults to hiera('bootstack_nodeid')
#
class tripleo::profile::base::neutron::opendaylight (
$step = hiera('step'),
- $primary_node = hiera('bootstrap_nodeid', undef),
+ $odl_api_ips = hiera('opendaylight_api_node_ips'),
+ $node_name = hiera('bootstack_nodeid')
) {
if $step >= 1 {
- # Configure ODL only on first node of the role where this service is
- # applied
- if $primary_node == downcase($::hostname) {
+ validate_array($odl_api_ips)
+ if empty($odl_api_ips) {
+ fail('No IPs assigned to OpenDaylight Api Service')
+ } elsif size($odl_api_ips) == 2 {
+ fail('2 node OpenDaylight deployments are unsupported. Use 1 or greater than 2')
+ } elsif size($odl_api_ips) > 2 {
+ $node_string = split($node_name, '-')
+ $ha_node_index = $node_string[-1] + 1
+ class { '::opendaylight':
+ enable_ha => true,
+ ha_node_ips => $odl_api_ips,
+ ha_node_index => $ha_node_index,
+ }
+ } else {
include ::opendaylight
}
}
diff --git a/manifests/profile/base/neutron/plugins/ml2/opendaylight.pp b/manifests/profile/base/neutron/plugins/ml2/opendaylight.pp
index c120931..2618d4f 100644
--- a/manifests/profile/base/neutron/plugins/ml2/opendaylight.pp
+++ b/manifests/profile/base/neutron/plugins/ml2/opendaylight.pp
@@ -30,6 +30,10 @@
# (Optional) Password to configure for OpenDaylight
# Defaults to 'admin'
#
+# [*odl_url_ip*]
+# (Optional) Virtual IP address for ODL Api Service
+# Defaults to hiera('opendaylight_api_vip')
+#
# [*conn_proto*]
# (Optional) Protocol to use to for ODL REST access
# Defaults to hiera('opendaylight::nb_connection_protocol')
@@ -43,14 +47,13 @@ class tripleo::profile::base::neutron::plugins::ml2::opendaylight (
$odl_port = hiera('opendaylight::odl_rest_port'),
$odl_username = hiera('opendaylight::username'),
$odl_password = hiera('opendaylight::password'),
+ $odl_url_ip = hiera('opendaylight_api_vip'),
$conn_proto = hiera('opendaylight::nb_connection_protocol'),
$step = hiera('step'),
) {
if $step >= 4 {
- $odl_url_ip = hiera('opendaylight_api_vip')
-
- if ! $odl_url_ip { fail('OpenDaylight Controller IP/VIP is Empty') }
+ if ! $odl_url_ip { fail('OpenDaylight API VIP is Empty') }
class { '::neutron::plugins::ml2::opendaylight':
odl_username => $odl_username,
diff --git a/manifests/profile/base/neutron/plugins/ovs/opendaylight.pp b/manifests/profile/base/neutron/plugins/ovs/opendaylight.pp
index 91c5168..4da8df9 100644
--- a/manifests/profile/base/neutron/plugins/ovs/opendaylight.pp
+++ b/manifests/profile/base/neutron/plugins/ovs/opendaylight.pp
@@ -30,6 +30,10 @@
# (Optional) List of OpenStack Controller IPs for ODL API
# Defaults to hiera('opendaylight_api_node_ips')
#
+# [*odl_url_ip*]
+# (Optional) Virtual IP address for ODL Api Service
+# Defaults to hiera('opendaylight_api_vip')
+#
# [*conn_proto*]
# (Optional) Protocol to use to for ODL REST access
# Defaults to hiera('opendaylight::nb_connection_protocol')
@@ -43,25 +47,25 @@ class tripleo::profile::base::neutron::plugins::ovs::opendaylight (
$odl_port = hiera('opendaylight::odl_rest_port'),
$odl_check_url = hiera('opendaylight_check_url'),
$odl_api_ips = hiera('opendaylight_api_node_ips'),
+ $odl_url_ip = hiera('opendaylight_api_vip'),
$conn_proto = hiera('opendaylight::nb_connection_protocol'),
$step = hiera('step'),
) {
if $step >= 4 {
- $opendaylight_controller_ip = $odl_api_ips[0]
- $odl_url_ip = hiera('opendaylight_api_vip')
-
- if ! $opendaylight_controller_ip { fail('OpenDaylight Controller IP is Empty') }
+ if empty($odl_api_ips) { fail('No IPs assigned to OpenDaylight Api Service') }
if ! $odl_url_ip { fail('OpenDaylight API VIP is Empty') }
# Build URL to check if ODL is up before connecting OVS
$opendaylight_url = "${conn_proto}://${odl_url_ip}:${odl_port}/${odl_check_url}"
+ $odl_ovsdb_str = join(regsubst($odl_api_ips, '.+', 'tcp:\0:6640'), ' ')
+
class { '::neutron::plugins::ovs::opendaylight':
tunnel_ip => hiera('neutron::agents::ml2::ovs::local_ip'),
odl_check_url => $opendaylight_url,
- odl_ovsdb_iface => "tcp:${opendaylight_controller_ip}:6640",
+ odl_ovsdb_iface => $odl_ovsdb_str,
}
}
}
diff --git a/manifests/profile/base/neutron/server.pp b/manifests/profile/base/neutron/server.pp
index 5d6909f..d67a40c 100644
--- a/manifests/profile/base/neutron/server.pp
+++ b/manifests/profile/base/neutron/server.pp
@@ -43,14 +43,6 @@
# (Optional) Whether TLS in the internal network is enabled or not.
# Defaults to hiera('enable_internal_tls', false)
#
-# [*generate_service_certificates*]
-# (Optional) Whether or not certmonger will generate certificates for
-# HAProxy. This could be as many as specified by the $certificates_specs
-# variable.
-# Note that this doesn't configure the certificates in haproxy, it merely
-# creates the certificates.
-# Defaults to hiera('generate_service_certificate', false).
-#
# [*l3_ha_override*]
# (Optional) Override the calculated value for neutron::server::l3_ha
# by default this is calculated to enable when DVR is not enabled
@@ -95,7 +87,6 @@ class tripleo::profile::base::neutron::server (
$certificates_specs = hiera('apache_certificates_specs', {}),
$dvr_enabled = hiera('neutron::server::router_distributed', false),
$enable_internal_tls = hiera('enable_internal_tls', false),
- $generate_service_certificates = hiera('generate_service_certificates', false),
$l3_ha_override = '',
$l3_nodes = hiera('neutron_l3_short_node_names', []),
$neutron_network = hiera('neutron_api_network', undef),
@@ -104,10 +95,6 @@ class tripleo::profile::base::neutron::server (
$tls_proxy_fqdn = undef,
$tls_proxy_port = 9696,
) {
- if $enable_internal_tls and $generate_service_certificates {
- ensure_resources('tripleo::certmonger::httpd', $certificates_specs)
- }
-
if $::hostname == downcase($bootstrap_node) {
$sync_db = true
} else {