summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--environments/puppet-pacemaker.yaml1
-rw-r--r--overcloud-resource-registry-puppet.yaml1
-rw-r--r--overcloud.yaml1
-rw-r--r--puppet/controller.yaml8
-rw-r--r--puppet/manifests/overcloud_controller.pp19
-rw-r--r--puppet/manifests/overcloud_controller_pacemaker.pp15
-rw-r--r--puppet/services/database/redis-base.yaml21
-rw-r--r--puppet/services/database/redis.yaml25
-rw-r--r--puppet/services/pacemaker/database/redis.yaml28
9 files changed, 80 insertions, 39 deletions
diff --git a/environments/puppet-pacemaker.yaml b/environments/puppet-pacemaker.yaml
index 679b79cb..614bd3a8 100644
--- a/environments/puppet-pacemaker.yaml
+++ b/environments/puppet-pacemaker.yaml
@@ -22,3 +22,4 @@ resource_registry:
OS::TripleO::Services::RabbitMQ: ../puppet/services/pacemaker/rabbitmq.yaml
OS::TripleO::Services::Loadbalancer: ../puppet/services/pacemaker/loadbalancer.yaml
OS::TripleO::Services::Memcached: ../puppet/services/pacemaker/memcached.yaml
+ OS::TripleO::Services::Redis: ../puppet/services/pacemaker/database/redis.yaml
diff --git a/overcloud-resource-registry-puppet.yaml b/overcloud-resource-registry-puppet.yaml
index 5a9d6e3a..559caf88 100644
--- a/overcloud-resource-registry-puppet.yaml
+++ b/overcloud-resource-registry-puppet.yaml
@@ -138,6 +138,7 @@ resource_registry:
OS::TripleO::Services::SwiftProxy: puppet/services/swift-proxy.yaml
OS::TripleO::Services::SaharaApi: puppet/services/sahara-api.yaml
OS::TripleO::Services::SaharaEngine: puppet/services/sahara-engine.yaml
+ OS::TripleO::Services::Redis: puppet/services/database/redis.yaml
parameter_defaults:
EnablePackageInstall: false
diff --git a/overcloud.yaml b/overcloud.yaml
index 82d7368e..b73f7a15 100644
--- a/overcloud.yaml
+++ b/overcloud.yaml
@@ -649,6 +649,7 @@ parameters:
- OS::TripleO::Services::Loadbalancer
- OS::TripleO::Services::Memcached
- OS::TripleO::Services::SwiftProxy
+ - OS::TripleO::Services::Redis
description: A list of service resources (configured in the Heat
resource_registry) which represent nested stacks
for each service that should get installed on the Controllers.
diff --git a/puppet/controller.yaml b/puppet/controller.yaml
index 62bb3013..99613f69 100644
--- a/puppet/controller.yaml
+++ b/puppet/controller.yaml
@@ -15,6 +15,8 @@ parameters:
description: The password for the aodh services.
type: string
hidden: true
+ #TODO(composable Redis): Remove the Redis password param
+ #As is used by ceilometer
CeilometerApiVirtualIP:
type: string
default: ''
@@ -516,8 +518,8 @@ parameters:
description: Set rabbit subscriber port, change this if using SSL
type: number
RedisPassword:
+ description: The password for Redis
type: string
- description: The password to access the Redis service
hidden: true
RedisVirtualIP:
type: string
@@ -1082,7 +1084,6 @@ resources:
SUBNET: {get_attr: [NetIpMap, net_ip_subnet_map, {get_param: [ServiceNetMap, HorizonNetwork]}]}
rabbitmq_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, RabbitMqNetwork]}]}
redis_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, RedisNetwork]}]}
- redis_password: {get_param: RedisPassword}
redis_vip: {get_param: RedisVirtualIP}
sahara_api_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, SaharaApiNetwork]}]}
memcached_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, MemcachedNetwork]}]}
@@ -1412,9 +1413,6 @@ resources:
rabbitmq::erlang_cookie: {get_input: rabbit_cookie}
# Redis
redis::bind: {get_input: redis_network}
- redis::requirepass: {get_input: redis_password}
- redis::masterauth: {get_input: redis_password}
- redis::sentinel_auth_pass: {get_input: redis_password}
redis_vip: {get_input: redis_vip}
# Firewall
tripleo::firewall::manage_firewall: {get_input: manage_firewall}
diff --git a/puppet/manifests/overcloud_controller.pp b/puppet/manifests/overcloud_controller.pp
index 439036a2..10570012 100644
--- a/puppet/manifests/overcloud_controller.pp
+++ b/puppet/manifests/overcloud_controller.pp
@@ -61,25 +61,6 @@ if hiera('step') >= 2 {
}
}
- # Redis
- $redis_node_ips = hiera('redis_node_ips')
- $redis_master_hostname = downcase(hiera('bootstrap_nodeid'))
-
- if $redis_master_hostname == $::hostname {
- $slaveof = undef
- } else {
- $slaveof = "${redis_master_hostname} 6379"
- }
- class {'::redis' :
- slaveof => $slaveof,
- }
-
- if count($redis_node_ips) > 1 {
- Class['::tripleo::redis_notification'] -> Service['redis-sentinel']
- include ::redis::sentinel
- include ::tripleo::redis_notification
- }
-
if str2bool(hiera('enable_galera', true)) {
$mysql_config_file = '/etc/my.cnf.d/galera.cnf'
} else {
diff --git a/puppet/manifests/overcloud_controller_pacemaker.pp b/puppet/manifests/overcloud_controller_pacemaker.pp
index abe586f4..fcefe936 100644
--- a/puppet/manifests/overcloud_controller_pacemaker.pp
+++ b/puppet/manifests/overcloud_controller_pacemaker.pp
@@ -108,12 +108,6 @@ if hiera('step') >= 1 {
}
}
- # Redis
- class { '::redis' :
- service_manage => false,
- notify_service => false,
- }
-
# Galera
if str2bool(hiera('enable_galera', true)) {
$mysql_config_file = '/etc/my.cnf.d/galera.cnf'
@@ -226,15 +220,6 @@ if hiera('step') >= 2 {
require => Class['::mysql::server'],
before => Exec['galera-ready'],
}
-
- pacemaker::resource::ocf { 'redis':
- ocf_agent_name => 'heartbeat:redis',
- master_params => '',
- meta_params => 'notify=true ordered=true interleave=true',
- resource_params => 'wait_last_known_master=true',
- require => Class['::redis'],
- }
-
}
$mysql_root_password = hiera('mysql::server::root_password')
$mysql_clustercheck_password = hiera('mysql_clustercheck_password')
diff --git a/puppet/services/database/redis-base.yaml b/puppet/services/database/redis-base.yaml
new file mode 100644
index 00000000..77b3c9f0
--- /dev/null
+++ b/puppet/services/database/redis-base.yaml
@@ -0,0 +1,21 @@
+heat_template_version: 2016-04-08
+
+description: >
+ OpenStack Redis service configured with Puppet
+
+parameters:
+ RedisPassword:
+ description: The password for Redis
+ type: string
+ hidden: true
+
+outputs:
+ role_data:
+ description: Role data for the redis role.
+ value:
+ config_settings:
+ redis::requirepass: {get_param: RedisPassword}
+ redis::masterauth: {get_param: RedisPassword}
+ redis::sentinel_auth_pass: {get_param: RedisPassword}
+ tripleo::loadbalancer::redis_password: {get_param: RedisPassword}
+
diff --git a/puppet/services/database/redis.yaml b/puppet/services/database/redis.yaml
new file mode 100644
index 00000000..2669592a
--- /dev/null
+++ b/puppet/services/database/redis.yaml
@@ -0,0 +1,25 @@
+heat_template_version: 2016-04-08
+
+description: >
+ OpenStack Redis service configured with Puppet
+
+parameters:
+ EndpointMap:
+ default: {}
+ description: Mapping of service endpoint -> protocol. Typically set
+ via parameter_defaults in the resource registry.
+ type: json
+
+resources:
+ RedisBase:
+ type: ./redis-base.yaml
+
+outputs:
+ role_data:
+ description: Role data for the redis role.
+ value:
+ config_settings:
+ map_merge:
+ - get_attr: [RedisBase, role_data, config_settings]
+ step_config: |
+ include ::tripleo::profile::base::database::redis
diff --git a/puppet/services/pacemaker/database/redis.yaml b/puppet/services/pacemaker/database/redis.yaml
new file mode 100644
index 00000000..0e46f8a3
--- /dev/null
+++ b/puppet/services/pacemaker/database/redis.yaml
@@ -0,0 +1,28 @@
+heat_template_version: 2016-04-08
+
+description: >
+ OpenStack Redis service configured with Puppet
+
+parameters:
+ EndpointMap:
+ default: {}
+ description: Mapping of service endpoint -> protocol. Typically set
+ via parameter_defaults in the resource registry.
+ type: json
+
+resources:
+ RedisBase:
+ type: ../../database/redis-base.yaml
+
+outputs:
+ role_data:
+ description: Role data for the Redis pacemaker role.
+ value:
+ config_settings:
+ map_merge:
+ - get_attr: [RedisBase, role_data, config_settings]
+ - tripleo::profile::pacemaker::database::redis::redis_vip: {get_input: redis_vip}
+ redis::service_manage: false
+ redis::notify_service: false
+ step_config: |
+ include ::tripleo::profile::pacemaker::database::redis