diff --git a/deployment/puppet/cluster/manifests/init.pp b/deployment/puppet/cluster/manifests/init.pp index 70769e174a..a9849f1c8a 100644 --- a/deployment/puppet/cluster/manifests/init.pp +++ b/deployment/puppet/cluster/manifests/init.pp @@ -57,17 +57,4 @@ class cluster ( Package['corosync'] -> File['ocf-fuel-path'] Package<| title == 'pacemaker' |> -> File['ocf-fuel-path'] - file { 'ns-ipaddr2-ocf': - path =>'/usr/lib/ocf/resource.d/fuel/ns_IPaddr2', - mode => '0755', - owner => root, - group => root, - source => 'puppet:///modules/cluster/ocf/ns_IPaddr2', - } - - Package['pacemaker'] -> File['ns-ipaddr2-ocf'] - File<| title == 'ocf-fuel-path' |> -> File['ns-ipaddr2-ocf'] - } -# -### diff --git a/deployment/puppet/mysql/manifests/server.pp b/deployment/puppet/mysql/manifests/server.pp index 481f63519f..2b32f63f9c 100644 --- a/deployment/puppet/mysql/manifests/server.pp +++ b/deployment/puppet/mysql/manifests/server.pp @@ -126,8 +126,6 @@ class mysql::server ( unless => "test -d $mysql::params::datadir/mysql", } - Class['openstack::corosync'] -> Cs_resource["p_${service_name}"] - file { '/tmp/repl_create.sql' : ensure => present, content => template('mysql/repl_create.sql.erb'), diff --git a/deployment/puppet/osnailyfacter/modular/cluster/cluster.pp b/deployment/puppet/osnailyfacter/modular/cluster/cluster.pp new file mode 100644 index 0000000000..fcbaeaa069 --- /dev/null +++ b/deployment/puppet/osnailyfacter/modular/cluster/cluster.pp @@ -0,0 +1,6 @@ +notice('MODULAR: cluster.pp') + +class { '::cluster': + internal_address => hiera('internal_address'), + unicast_addresses => ipsort(values(hiera('controller_internal_addresses'))), +} diff --git a/deployment/puppet/osnailyfacter/modular/cluster/tasks.yaml b/deployment/puppet/osnailyfacter/modular/cluster/tasks.yaml new file mode 100644 index 0000000000..bc9edd5636 --- /dev/null +++ b/deployment/puppet/osnailyfacter/modular/cluster/tasks.yaml @@ -0,0 +1,9 @@ +- id: cluster + type: puppet + groups: [primary-controller, controller] + required_for: [top-role-controller, deploy] + requires: [hosts, firewall] + parameters: + puppet_manifest: /etc/puppet/modules/osnailyfacter/modular/cluster/cluster.pp + puppet_modules: /etc/puppet/modules + timeout: 3600 diff --git a/deployment/puppet/osnailyfacter/modular/controller.pp b/deployment/puppet/osnailyfacter/modular/controller.pp index d3204bcf60..efef05a960 100644 --- a/deployment/puppet/osnailyfacter/modular/controller.pp +++ b/deployment/puppet/osnailyfacter/modular/controller.pp @@ -483,6 +483,14 @@ class compact_controller ( } class virtual_ips () { + file { 'ns-ipaddr2-ocf': + path =>'/usr/lib/ocf/resource.d/fuel/ns_IPaddr2', + mode => '0755', + owner => root, + group => root, + source => 'puppet:///modules/cluster/ocf/ns_IPaddr2', + } + cluster::virtual_ips { $::vip_keys: vips => $::vips, } @@ -551,13 +559,6 @@ if $use_ceph { ################################################################# include osnailyfacter::test_controller -class { '::cluster': - stage => 'corosync_setup', - internal_address => $::internal_address, - unicast_addresses => $::controller_nodes, -} - -Class['::cluster']-> class { 'virtual_ips' : stage => 'corosync_setup', } @@ -889,9 +890,6 @@ package { 'screen': ensure => present, } -# Make corosync and pacemaker setup and configuration before all services provided by pacemaker -Class['openstack::corosync'] -> Service<| provider=='pacemaker' |> - # Reduce swapiness on controllers, see LP#1413702 sysctl::value { 'vm.swappiness': value => "10"