aboutsummaryrefslogtreecommitdiffstats
path: root/puppet
diff options
context:
space:
mode:
Diffstat (limited to 'puppet')
-rw-r--r--puppet/all-nodes-config.yaml4
-rw-r--r--puppet/ceph-storage-puppet.yaml10
-rw-r--r--puppet/cinder-storage-puppet.yaml13
-rw-r--r--puppet/compute-puppet.yaml8
-rw-r--r--puppet/controller-puppet.yaml6
-rw-r--r--puppet/manifests/overcloud_controller.pp88
-rw-r--r--puppet/swift-storage-puppet.yaml9
7 files changed, 99 insertions, 39 deletions
diff --git a/puppet/all-nodes-config.yaml b/puppet/all-nodes-config.yaml
index 7a4df796..9345e5c5 100644
--- a/puppet/all-nodes-config.yaml
+++ b/puppet/all-nodes-config.yaml
@@ -54,10 +54,10 @@ resources:
list_join:
- ','
- {get_param: controller_ips}
- rabbit_node_names:
+ rabbit_node_ips:
list_join:
- ','
- - {get_param: controller_names}
+ - {get_param: controller_ips}
mongo_node_ips:
list_join:
- ','
diff --git a/puppet/ceph-storage-puppet.yaml b/puppet/ceph-storage-puppet.yaml
index 4ce16225..660ea30a 100644
--- a/puppet/ceph-storage-puppet.yaml
+++ b/puppet/ceph-storage-puppet.yaml
@@ -45,6 +45,15 @@ resources:
NodeUserData:
type: OS::TripleO::NodeUserData
+ NetworkConfig:
+ type: OS::TripleO::CephStorage::Net::SoftwareConfig
+
+ NetworkDeployment:
+ type: OS::TripleO::SoftwareDeployment
+ properties:
+ config: {get_attr: [NetworkConfig, config_id]}
+ server: {get_resource: CephStorage}
+
CephStorageDeployment:
type: OS::Heat::StructuredDeployment
properties:
@@ -57,6 +66,7 @@ resources:
params:
server: {get_param: NtpServer}
enable_package_install: {get_param: EnablePackageInstall}
+
CephStorageConfig:
type: OS::Heat::StructuredConfig
properties:
diff --git a/puppet/cinder-storage-puppet.yaml b/puppet/cinder-storage-puppet.yaml
index 3e55ec85..de96809a 100644
--- a/puppet/cinder-storage-puppet.yaml
+++ b/puppet/cinder-storage-puppet.yaml
@@ -75,10 +75,10 @@ parameters:
description: Name of an existing EC2 KeyPair to enable SSH access to the instances
type: string
RabbitPassword:
- default: ''
+ default: 'guest'
type: string
RabbitUserName:
- default: ''
+ default: 'guest'
type: string
RabbitClientUseSSL:
default: false
@@ -123,6 +123,15 @@ resources:
NodeUserData:
type: OS::TripleO::NodeUserData
+ NetworkConfig:
+ type: OS::TripleO::BlockStorage::Net::SoftwareConfig
+
+ NetworkDeployment:
+ type: OS::TripleO::SoftwareDeployment
+ properties:
+ config: {get_attr: [NetworkConfig, config_id]}
+ server: {get_resource: BlockStorage}
+
BlockStorageDeployment:
type: OS::Heat::StructuredDeployment
properties:
diff --git a/puppet/compute-puppet.yaml b/puppet/compute-puppet.yaml
index 11910d79..a31ea858 100644
--- a/puppet/compute-puppet.yaml
+++ b/puppet/compute-puppet.yaml
@@ -110,13 +110,13 @@ parameters:
network) - if changing this either use different post-install network
scripts or be sure to keep 'datacentre' as a mapping network name.
type: string
- default: ""
+ default: "datacentre:br-ex"
NeutronEnableTunnelling:
type: string
default: "True"
NeutronFlatNetworks:
type: string
- default: ''
+ default: 'datacentre'
description: >
If set, flat networks to configure in neutron plugins.
NeutronHost:
@@ -139,7 +139,7 @@ parameters:
type: string
hidden: true
NeutronPhysicalBridge:
- default: ''
+ default: 'br-ex'
description: An OVS bridge to create for accessing external networks.
type: string
NeutronPublicInterface:
@@ -268,7 +268,7 @@ resources:
type: OS::TripleO::NodeUserData
NetworkConfig:
- type: OS::TripleO::Net::SoftwareConfig
+ type: OS::TripleO::Compute::Net::SoftwareConfig
NetworkDeployment:
type: OS::TripleO::SoftwareDeployment
diff --git a/puppet/controller-puppet.yaml b/puppet/controller-puppet.yaml
index a904e041..4e04eb0e 100644
--- a/puppet/controller-puppet.yaml
+++ b/puppet/controller-puppet.yaml
@@ -221,7 +221,7 @@ parameters:
network) - if changing this either use different post-install network
scripts or be sure to keep 'datacentre' as a mapping network name.
type: string
- default: ""
+ default: "datacentre:br-ex"
NeutronDnsmasqOptions:
default: 'dhcp-option-force=26,1400'
description: Dnsmasq options for neutron-dhcp-agent. The default value here forces MTU to be set to 1400 to account for the gre tunnel overhead.
@@ -257,7 +257,7 @@ parameters:
default: "True"
NeutronFlatNetworks:
type: string
- default: ''
+ default: 'datacentre'
description: If set, flat networks to configure in neutron plugins.
NeutronL3HA:
default: 'False'
@@ -431,7 +431,7 @@ resources:
type: OS::TripleO::NodeUserData
NetworkConfig:
- type: OS::TripleO::Net::SoftwareConfig
+ type: OS::TripleO::Controller::Net::SoftwareConfig
NetworkDeployment:
type: OS::TripleO::SoftwareDeployment
diff --git a/puppet/manifests/overcloud_controller.pp b/puppet/manifests/overcloud_controller.pp
index b1ccf3d7..7e7f2fb2 100644
--- a/puppet/manifests/overcloud_controller.pp
+++ b/puppet/manifests/overcloud_controller.pp
@@ -24,23 +24,25 @@ if !str2bool(hiera('enable_package_install', 'false')) {
}
}
+$enable_pacemaker = str2bool(hiera('enable_pacemaker'))
+$enable_keepalived = !$enable_pacemaker
+if $::hostname == downcase(hiera('bootstrap_nodeid')) {
+ $pacemaker_master = true
+} else {
+ $pacemaker_master = false
+}
+
if hiera('step') >= 1 {
$controller_node_ips = split(hiera('controller_node_ips'), ',')
- $enable_pacemaker = str2bool(hiera('enable_pacemaker'))
- $enable_keepalived = !$enable_pacemaker
class { '::tripleo::loadbalancer' :
controller_hosts => $controller_node_ips,
+ manage_vip => $enable_keepalived,
}
if $enable_pacemaker {
$pacemaker_cluster_members = regsubst(hiera('controller_node_ips'), ',', ' ', 'G')
- if $::hostname == downcase(hiera('bootstrap_nodeid')) {
- $pacemaker_master = true
- } else {
- $pacemaker_master = false
- }
user { 'hacluster':
ensure => present,
} ->
@@ -54,6 +56,19 @@ if hiera('step') >= 1 {
class { '::pacemaker::stonith':
disable => true,
}
+ if $pacemaker_master {
+ $control_vip = hiera('tripleo::loadbalancer::controller_virtual_ip')
+ pacemaker::resource::ip { 'control_vip':
+ ip_address => $control_vip,
+ }
+ $public_vip = hiera('tripleo::loadbalancer::public_virtual_ip')
+ pacemaker::resource::ip { 'public_vip':
+ ip_address => $public_vip,
+ }
+ pacemaker::resource::systemd { 'haproxy':
+ clone => true,
+ }
+ }
}
}
@@ -168,29 +183,46 @@ if hiera('step') >= 2 {
allowed_hosts => $allowed_hosts,
}
- $rabbit_nodes = split(downcase(hiera('rabbit_node_names', $::hostname)), ',')
- if count($rabbit_nodes) > 1 {
- $rabbit_cluster = true
- }
- else {
- $rabbit_cluster = false
- }
- class { 'rabbitmq':
- config_cluster => $rabbit_cluster,
- cluster_nodes => $rabbit_nodes,
- node_ip_address => hiera('controller_host'),
- }
- if $rabbit_cluster {
- rabbitmq_policy { 'ha-all@/':
- pattern => '^(?!amq\.).*',
- definition => {
- 'ha-mode' => 'all',
- 'ha-sync-mode' => 'automatic',
+ if $enable_pacemaker {
+ # the module ignores erlang_cookie if cluster_config is false
+ file { '/var/lib/rabbitmq/.erlang.cookie':
+ ensure => 'present',
+ owner => 'rabbitmq',
+ group => 'rabbitmq',
+ mode => '0400',
+ content => hiera('rabbitmq::erlang_cookie'),
+ replace => true,
+ } ->
+ class { '::rabbitmq':
+ service_manage => false,
+ environment_variables => {
+ 'RABBITMQ_NODENAME' => "rabbit@$::hostname",
},
}
- }
- rabbitmq_vhost { '/':
- provider => 'rabbitmqctl',
+ if $pacemaker_master {
+ pacemaker::resource::ocf { 'rabbitmq':
+ resource_name => 'heartbeat:rabbitmq-cluster',
+ options => 'set_policy=\'ha-all ^(?!amq\.).* {"ha-mode":"all"}\'',
+ clone => true,
+ require => Class['::rabbitmq'],
+ }
+ }
+ } else {
+ $rabbit_nodes = split(hiera('rabbit_node_ips'), ',')
+ if count($rabbit_nodes) > 1 {
+ class { '::rabbitmq':
+ config_cluster => true,
+ cluster_nodes => $rabbit_nodes,
+ }
+ rabbitmq_policy { 'ha-all@/':
+ pattern => '^(?!amq\.).*',
+ definition => {
+ 'ha-mode' => 'all',
+ },
+ }
+ } else {
+ include ::rabbitmq
+ }
}
# pre-install swift here so we can build rings
diff --git a/puppet/swift-storage-puppet.yaml b/puppet/swift-storage-puppet.yaml
index 6f861d88..c3eb9536 100644
--- a/puppet/swift-storage-puppet.yaml
+++ b/puppet/swift-storage-puppet.yaml
@@ -68,6 +68,15 @@ resources:
NodeUserData:
type: OS::TripleO::NodeUserData
+ NetworkConfig:
+ type: OS::TripleO::ObjectStorage::Net::SoftwareConfig
+
+ NetworkDeployment:
+ type: OS::TripleO::SoftwareDeployment
+ properties:
+ config: {get_attr: [NetworkConfig, config_id]}
+ server: {get_resource: SwiftStorage}
+
SwiftStorageHieraConfig:
type: OS::Heat::StructuredConfig
properties: