system-config/modules/openstack_project/manifests/cacti.pp
Clark Boylan 2820835473 Add sixth elasticsearch node.
* manifests/site.pp: Put elasticsearch nodes in a list variable that is
reused.

* modules/logstash/templates/elasticsearch.yml.erb: Update cluster
settings to be more appropriate for the larger cluster size, including
changing the minimum number of master eligible nodes that must be seen
before becoming operational in a cluster. Should help prevent split
brained clusters.

* modules/openstack_project/manifests/cacti.pp: Add new node to cacti
node list.

Change-Id: I9a18422aa56a56b9ad030892a312772d9b6b2a79
2013-08-02 13:22:47 -07:00

98 lines
2.9 KiB
Puppet

# Class to configure cacti on a node.
# Takes a list of sysadmin email addresses as a parameter. Exim will be
# configured to email cron spam and other alerts to this list of admins.
class openstack_project::cacti (
$sysadmins = []
) {
class { 'openstack_project::server':
iptables_public_tcp_ports => [80, 443],
sysadmins => $sysadmins,
}
include apache
package { 'cacti':
ensure => present,
}
file { '/usr/local/share/cacti/resource/snmp_queries':
ensure => directory,
owner => 'root',
}
file { '/usr/local/share/cacti/resource/snmp_queries/net-snmp_devio.xml':
ensure => present,
source => 'puppet:///modules/openstack_project/cacti/net-snmp_devio.xml',
mode => '0644',
owner => 'root',
group => 'root',
require => File['/usr/local/share/cacti/resource/snmp_queries'],
}
file { '/var/lib/cacti/linux_host.xml':
ensure => present,
source => 'puppet:///modules/openstack_project/cacti/linux_host.xml',
mode => '0644',
owner => 'root',
group => 'root',
require => File[
'/usr/local/share/cacti/resource/snmp_queries/net-snmp_devio.xml'
],
}
file { '/usr/local/bin/create_graphs.sh':
ensure => present,
source => 'puppet:///modules/openstack_project/cacti/create_graphs.sh',
mode => '0744',
owner => 'root',
group => 'root',
}
exec { 'cacti_import_xml':
command => '/usr/bin/php -q /usr/share/cacti/cli/import_template.php --filename=/var/lib/cacti/linux_host.xml --with-template-rras',
cwd => '/usr/share/cacti/cli',
require => File['/var/lib/cacti/linux_host.xml'],
}
$cacti_hosts = [
# community is currently not running puppet.
#'community.openstack.org',
'ci-puppetmaster.openstack.org',
'eavesdrop.openstack.org',
'elasticsearch.openstack.org',
'elasticsearch2.openstack.org',
'elasticsearch3.openstack.org',
'elasticsearch4.openstack.org',
'elasticsearch5.openstack.org',
'elasticsearch6.openstack.org',
'etherpad.openstack.org',
'graphite.openstack.org',
'jenkins.openstack.org',
'jenkins01.openstack.org',
'jenkins02.openstack.org',
'jenkins-dev.openstack.org',
'lists.openstack.org',
'logstash.openstack.org',
'logstash-worker1.openstack.org',
'logstash-worker2.openstack.org',
'logstash-worker3.openstack.org',
'logstash-worker4.openstack.org',
'logstash-worker5.openstack.org',
'logstash-worker6.openstack.org',
'logstash-worker7.openstack.org',
'logstash-worker8.openstack.org',
'paste.openstack.org',
'pbx.openstack.org',
'planet.openstack.org',
'puppet-dashboard.openstack.org',
'pypi.openstack.org',
'review.openstack.org',
'review-dev.openstack.org',
'static.openstack.org',
'wiki.openstack.org',
'zuul.openstack.org',
]
openstack_project::cacti_device { $cacti_hosts: }
}