aboutsummaryrefslogtreecommitdiffstats
path: root/manifests/profile/base
diff options
context:
space:
mode:
Diffstat (limited to 'manifests/profile/base')
-rw-r--r--manifests/profile/base/database/mongodb.pp54
-rw-r--r--manifests/profile/base/database/mongodbcommon.pp52
-rw-r--r--manifests/profile/base/keystone.pp17
-rw-r--r--manifests/profile/base/neutron.pp9
-rw-r--r--manifests/profile/base/neutron/ml2.pp7
-rw-r--r--manifests/profile/base/neutron/plugins/plumgrid.pp37
-rw-r--r--manifests/profile/base/neutron/server.pp15
-rw-r--r--manifests/profile/base/nova.pp14
-rw-r--r--manifests/profile/base/nova/api.pp51
-rw-r--r--manifests/profile/base/nova/compute.pp35
-rw-r--r--manifests/profile/base/nova/conductor.pp2
-rw-r--r--manifests/profile/base/nova/consoleauth.pp35
-rw-r--r--manifests/profile/base/nova/scheduler.pp36
-rw-r--r--manifests/profile/base/nova/vncproxy.pp35
-rw-r--r--manifests/profile/base/snmp.pp50
-rw-r--r--manifests/profile/base/swift/proxy.pp1
16 files changed, 423 insertions, 27 deletions
diff --git a/manifests/profile/base/database/mongodb.pp b/manifests/profile/base/database/mongodb.pp
new file mode 100644
index 0000000..4c53c9c
--- /dev/null
+++ b/manifests/profile/base/database/mongodb.pp
@@ -0,0 +1,54 @@
+# Copyright 2016 Red Hat, Inc.
+#
+# 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::database::mongodb
+#
+# Mongodb profile for tripleo
+#
+# === Parameters
+#
+# [*mongodb_replset*]
+# Mongodb replicaset name
+#
+# [*bootstrap_node*]
+# (Optional) The hostname of the node responsible for bootstrapping tasks
+# Defaults to hiera('bootstrap_nodeid')
+#
+# [*step*]
+# (Optional) The current step in deployment. See tripleo-heat-templates
+# for more details.
+# Defaults to hiera('step')
+#
+class tripleo::profile::base::database::mongodb (
+ $mongodb_replset,
+ $bootstrap_node = downcase(hiera('bootstrap_nodeid')),
+ $step = hiera('step'),
+) {
+
+ if $step >= 2 {
+
+ include ::mongodb::globals
+ include ::mongodb::client
+ include ::mongodb::server
+
+ include ::tripleo::profile::base::database::mongodbcommon
+
+ if $bootstrap_node == $::hostname {
+ mongodb_replset { $mongodb_replset :
+ members => $tripleo::profile::base::database::mongodbcommon::mongo_node_ips_with_port_nobr,
+ }
+ }
+
+ }
+}
diff --git a/manifests/profile/base/database/mongodbcommon.pp b/manifests/profile/base/database/mongodbcommon.pp
new file mode 100644
index 0000000..6530730
--- /dev/null
+++ b/manifests/profile/base/database/mongodbcommon.pp
@@ -0,0 +1,52 @@
+# Copyright 2016 Red Hat, Inc.
+#
+# 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::database::mongodb
+#
+# Mongodb profile for tripleo
+#
+# === Parameters
+#
+# [*mongodb_node_ips*]
+# List of The mongodb node ip addresses
+#
+# [*mongodb_ipv6_enabled*]
+# A boolean value for mongodb server ipv6 is enabled or not
+# Defaults to false
+#
+class tripleo::profile::base::database::mongodbcommon (
+ $mongodb_node_ips = hiera('mongo_node_ips'),
+ $mongodb_ipv6_enabled = false,
+) {
+
+ $port = '27017'
+
+ # NOTE(gfidente): the following vars are needed on all nodes so they
+ # need to stay out of pacemaker_master conditional.
+ # The addresses mangling will hopefully go away when we'll be able to
+ # configure the connection string via hostnames, until then, we need to pass
+ # the list of IPv6 addresses *with* port and without the brackets as 'members'
+ # argument for the 'mongodb_replset' resource.
+ if str2bool($mongodb_ipv6_enabled) {
+ $mongo_node_ips_with_port_prefixed = prefix($mongodb_node_ips, '[')
+ $mongo_node_ips_with_port = suffix(
+ $mongo_node_ips_with_port_prefixed, "]:${port}")
+ $mongo_node_ips_with_port_nobr = suffix($mongodb_node_ips, ":${port}")
+ } else {
+ $mongo_node_ips_with_port = suffix($mongodb_node_ips, ":${port}")
+ $mongo_node_ips_with_port_nobr = suffix($mongodb_node_ips, ":${port}")
+ }
+ $mongo_node_string = join($mongo_node_ips_with_port, ',')
+
+}
diff --git a/manifests/profile/base/keystone.pp b/manifests/profile/base/keystone.pp
index a5060b8..706b78f 100644
--- a/manifests/profile/base/keystone.pp
+++ b/manifests/profile/base/keystone.pp
@@ -22,10 +22,6 @@
# (Optional) Whether to run db sync
# Defaults to true
#
-# [*bootstrap_master*]
-# (Optional) The hostname of the node responsible for bootstrapping
-# Defaults to hiera('bootstrap_nodeid')
-#
# [*manage_roles*]
# (Optional) whether to create keystone admin role
# Defaults to true
@@ -44,12 +40,11 @@
# Defaults to hiera('step')
#
class tripleo::profile::base::keystone (
- $sync_db = true,
- $bootstrap_master = undef,
- $manage_roles = true,
- $manage_endpoint = true,
- $manage_db_purge = hiera('keystone_enable_db_purge', true),
- $step = hiera('step'),
+ $sync_db = true,
+ $manage_roles = true,
+ $manage_endpoint = true,
+ $manage_db_purge = hiera('keystone_enable_db_purge', true),
+ $step = hiera('step'),
) {
if $step >= 3 and $sync_db {
@@ -59,7 +54,7 @@ class tripleo::profile::base::keystone (
if $step >= 4 or ( $step >= 3 and $sync_db ) {
class { '::keystone':
sync_db => $sync_db,
- enable_bootstrap => $bootstrap_master,
+ enable_bootstrap => $sync_db,
}
include ::keystone::config
diff --git a/manifests/profile/base/neutron.pp b/manifests/profile/base/neutron.pp
index 2958170..d5efa81 100644
--- a/manifests/profile/base/neutron.pp
+++ b/manifests/profile/base/neutron.pp
@@ -18,14 +18,19 @@
#
# === Parameters
#
+# [*sync_db*]
+# (Optional) Whether to run db sync
+# Defaults to true
+#
# [*step*]
# (Optional) The current step of the deployment
# Defaults to hiera('step')
#
class tripleo::profile::base::neutron (
- $step = hiera('step'),
+ $sync_db = true,
+ $step = hiera('step'),
) {
- if $step >= 4 {
+ if hiera('step') >= 4 or ( hiera('step') >= 3 and $sync_db ) {
include ::neutron
include ::neutron::config
}
diff --git a/manifests/profile/base/neutron/ml2.pp b/manifests/profile/base/neutron/ml2.pp
index 47b1b3c..d18638e 100644
--- a/manifests/profile/base/neutron/ml2.pp
+++ b/manifests/profile/base/neutron/ml2.pp
@@ -22,6 +22,10 @@
# (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.
@@ -29,10 +33,11 @@
#
class tripleo::profile::base::neutron::ml2 (
$mechanism_drivers = hiera('neutron::plugins::ml2::mechanism_drivers'),
+ $sync_db = true,
$step = hiera('step'),
) {
- if $step >= 4 {
+ if $step >= 4 or ( $step >= 3 and $sync_db ) {
include ::neutron::plugins::ml2
include ::tripleo::profile::base::neutron
diff --git a/manifests/profile/base/neutron/plugins/plumgrid.pp b/manifests/profile/base/neutron/plugins/plumgrid.pp
new file mode 100644
index 0000000..7f645b9
--- /dev/null
+++ b/manifests/profile/base/neutron/plugins/plumgrid.pp
@@ -0,0 +1,37 @@
+# Copyright 2016 PLUMgrid, Inc.
+#
+# 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::plugins::plumgrid
+#
+# PLUMgrid Neutron profile for tripleo
+#
+# === Parameters
+#
+# [*step*]
+# (Optional) The current step in deployment. See tripleo-heat-templates
+# for more details.
+# Defaults to hiera('step')
+#
+# [*sync_db*]
+# (Optional) Whether to run Neutron DB sync operations
+# Defaults to undef
+#
+class tripleo::profile::base::neutron::plugins::plumgrid (
+ $step = hiera('step'),
+ $sync_db = true,
+) {
+ if $step >= 4 or ( $step >= 3 and $sync_db ) {
+ include ::neutron::plugins::plumgrid
+ }
+}
diff --git a/manifests/profile/base/neutron/server.pp b/manifests/profile/base/neutron/server.pp
index 14af56e..320f83c 100644
--- a/manifests/profile/base/neutron/server.pp
+++ b/manifests/profile/base/neutron/server.pp
@@ -18,31 +18,24 @@
#
# === Parameters
#
-# [*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::server (
- $sync_db = true,
$step = hiera('step'),
) {
include ::tripleo::profile::base::neutron
- if $step >= 3 and $sync_db {
+ if $step >= 2 {
include ::neutron::db::mysql
}
- if $step >= 4 or ($step >=3 and $sync_db) {
+ if $step >= 4 {
include ::neutron::server::notifications
-
- class { '::neutron::server':
- sync_db => $sync_db,
- }
+ include ::neutron::server
}
+
}
diff --git a/manifests/profile/base/nova.pp b/manifests/profile/base/nova.pp
index abedf37..66f0d7d 100644
--- a/manifests/profile/base/nova.pp
+++ b/manifests/profile/base/nova.pp
@@ -25,8 +25,20 @@
class tripleo::profile::base::nova (
$step = hiera('step'),
) {
- if $step >= 4 {
+
+ if hiera('nova::use_ipv6', false) {
+ $memcached_servers = suffix(hiera('memcache_node_ips_v6'), ':11211')
+ } else {
+ $memcached_servers = suffix(hiera('memcache_node_ips'), ':11211')
+ }
+ if $step >= 3 {
include ::nova
+ # TODO(emilien): once we merge https://review.openstack.org/#/c/325983/
+ # let's override the value this way.
+ warning('Overriding memcached_servers from puppet-tripleo until 325983 lands.')
+ Nova {
+ memcached_servers => $memcached_servers,
+ }
include ::nova::config
}
}
diff --git a/manifests/profile/base/nova/api.pp b/manifests/profile/base/nova/api.pp
new file mode 100644
index 0000000..4064b1e
--- /dev/null
+++ b/manifests/profile/base/nova/api.pp
@@ -0,0 +1,51 @@
+# Copyright 2016 Red Hat, Inc.
+#
+# 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::nova::api
+#
+# Nova API profile for tripleo
+#
+# === Parameters
+#
+# [*step*]
+# (Optional) The current step in deployment. See tripleo-heat-templates
+# for more details.
+# Defaults to hiera('step')
+#
+# [*sync_db*]
+# (Optional) Whether to run db sync
+# Defaults to true
+#
+class tripleo::profile::base::nova::api (
+ $step = hiera('step'),
+ $sync_db = true,
+) {
+
+ include ::tripleo::profile::base::nova
+
+ if $step >= 2 and $sync_db {
+ include ::nova::db::mysql
+ include ::nova::db::mysql_api
+ Exec<| title == 'galera-ready'|> -> Anchor['nova::db::begin']
+ }
+
+ if $step >= 4 or ($step >= 3 and $sync_db) {
+ class { '::nova::api':
+ sync_db => $sync_db,
+ sync_db_api => $sync_db,
+ }
+ include ::nova::network::neutron
+ }
+}
+
diff --git a/manifests/profile/base/nova/compute.pp b/manifests/profile/base/nova/compute.pp
new file mode 100644
index 0000000..ae37d4a
--- /dev/null
+++ b/manifests/profile/base/nova/compute.pp
@@ -0,0 +1,35 @@
+# Copyright 2016 Red Hat, Inc.
+#
+# 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::nova::compute
+#
+# Nova Compute 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::nova::compute (
+ $step = hiera('step'),
+) {
+
+ if $step >= 4 {
+ include ::tripleo::profile::base::nova
+ include ::nova::compute
+ }
+
+}
diff --git a/manifests/profile/base/nova/conductor.pp b/manifests/profile/base/nova/conductor.pp
index 494bbc7..04c9d06 100644
--- a/manifests/profile/base/nova/conductor.pp
+++ b/manifests/profile/base/nova/conductor.pp
@@ -27,8 +27,8 @@ class tripleo::profile::base::nova::conductor (
$step = hiera('step'),
) {
+ include ::tripleo::profile::base::nova
if $step >= 4 {
- include ::tripleo::profile::base::nova
include ::nova::conductor
}
diff --git a/manifests/profile/base/nova/consoleauth.pp b/manifests/profile/base/nova/consoleauth.pp
new file mode 100644
index 0000000..442cf84
--- /dev/null
+++ b/manifests/profile/base/nova/consoleauth.pp
@@ -0,0 +1,35 @@
+# Copyright 2016 Red Hat, Inc.
+#
+# 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::nova::consoleauth
+#
+# Nova Consoleauth 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::nova::consoleauth (
+ $step = hiera('step'),
+) {
+
+ if $step >= 4 {
+ include ::tripleo::profile::base::nova
+ include ::nova::consoleauth
+ }
+
+}
diff --git a/manifests/profile/base/nova/scheduler.pp b/manifests/profile/base/nova/scheduler.pp
new file mode 100644
index 0000000..13b4e82
--- /dev/null
+++ b/manifests/profile/base/nova/scheduler.pp
@@ -0,0 +1,36 @@
+# Copyright 2016 Red Hat, Inc.
+#
+# 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::nova::scheduler
+#
+# Nova Scheduler 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::nova::scheduler (
+ $step = hiera('step'),
+) {
+
+ if $step >= 4 {
+ include ::tripleo::profile::base::nova
+ include ::nova::scheduler
+ include ::nova::scheduler::filter
+ }
+
+}
diff --git a/manifests/profile/base/nova/vncproxy.pp b/manifests/profile/base/nova/vncproxy.pp
new file mode 100644
index 0000000..aa0cc7b
--- /dev/null
+++ b/manifests/profile/base/nova/vncproxy.pp
@@ -0,0 +1,35 @@
+# Copyright 2016 Red Hat, Inc.
+#
+# 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::nova::vncproxy
+#
+# Nova vncproxy 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::nova::vncproxy (
+ $step = hiera('step'),
+) {
+
+ if $step >= 4 {
+ include ::tripleo::profile::base::nova
+ include ::nova::vncproxy
+ }
+
+}
diff --git a/manifests/profile/base/snmp.pp b/manifests/profile/base/snmp.pp
new file mode 100644
index 0000000..40f7393
--- /dev/null
+++ b/manifests/profile/base/snmp.pp
@@ -0,0 +1,50 @@
+# Copyright 2016 Red Hat, Inc.
+#
+# 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::snmp
+#
+# SNMP profile for tripleo
+#
+# === Parameters
+#
+# [*step*]
+# (Optional) The current step in deployment. See tripleo-heat-templates
+# for more details.
+# Defaults to hiera('step')
+#
+# [*snmpd_user*]
+# The SNMP username
+# Defaults to hiera('snmpd_readonly_user_name')
+#
+# [*snmpd_password*]
+# The SNMP password
+# Defaults to hiera('snmpd_readonly_user_password')
+#
+class tripleo::profile::base::snmp (
+ $step = hiera('step'),
+ $snmpd_user = hiera('snmpd_readonly_user_name'),
+ $snmpd_password = hiera('snmpd_readonly_user_password'),
+) {
+
+ if $step >= 4 {
+ snmp::snmpv3_user { $snmpd_user:
+ authtype => 'MD5',
+ authpass => $snmpd_password,
+ }
+ class { '::snmp':
+ agentaddress => ['udp:161','udp6:[::1]:161'],
+ snmpd_config => [ join(['createUser ', $snmpd_user, ' MD5 "', $snmpd_password, '"']), join(['rouser ', $snmpd_user]), 'proc cron', 'includeAllDisks 10%', 'master agentx', 'trapsink localhost public', 'iquerySecName internalUser', 'rouser internalUser', 'defaultMonitors yes', 'linkUpDownNotifications yes' ],
+ }
+ }
+}
diff --git a/manifests/profile/base/swift/proxy.pp b/manifests/profile/base/swift/proxy.pp
index 58e2b6f..40e61ae 100644
--- a/manifests/profile/base/swift/proxy.pp
+++ b/manifests/profile/base/swift/proxy.pp
@@ -40,5 +40,6 @@ class tripleo::profile::base::swift::proxy (
include ::swift::proxy::catch_errors
include ::swift::proxy::tempurl
include ::swift::proxy::formpost
+ include ::swift::proxy::bulk
}
}