2012-11-15 14:25:13 -08:00
|
|
|
# == Class: openstack_project::server
|
|
|
|
#
|
2012-07-20 18:56:35 -07:00
|
|
|
# A server that we expect to run for some time
|
2012-08-05 13:02:21 -05:00
|
|
|
class openstack_project::server (
|
|
|
|
$iptables_public_tcp_ports = [],
|
2012-11-29 15:58:31 -08:00
|
|
|
$iptables_rules4 = [],
|
|
|
|
$iptables_rules6 = [],
|
2012-09-06 10:32:48 -07:00
|
|
|
$sysadmins = [],
|
2012-11-15 14:25:13 -08:00
|
|
|
$certname = $::fqdn
|
2012-09-06 10:32:48 -07:00
|
|
|
) {
|
2012-07-20 18:56:35 -07:00
|
|
|
class { 'openstack_project::template':
|
2012-08-05 13:02:21 -05:00
|
|
|
iptables_public_tcp_ports => $iptables_public_tcp_ports,
|
2012-11-29 15:58:31 -08:00
|
|
|
iptables_rules4 => $iptables_rules4,
|
|
|
|
iptables_rules6 => $iptables_rules6,
|
2012-11-15 14:25:13 -08:00
|
|
|
certname => $certname,
|
2012-07-20 18:56:35 -07:00
|
|
|
}
|
|
|
|
class { 'exim':
|
2012-11-15 14:25:13 -08:00
|
|
|
sysadmin => $sysadmins,
|
2012-07-20 18:56:35 -07:00
|
|
|
}
|
2013-02-20 04:12:13 +00:00
|
|
|
|
2013-04-24 03:32:06 +00:00
|
|
|
if $::osfamily == 'Debian' {
|
2013-05-14 18:44:44 +00:00
|
|
|
# Custom rsyslog config to disable /dev/xconsole noise on Debuntu servers
|
2013-02-20 04:12:13 +00:00
|
|
|
file { '/etc/rsyslog.d/50-default.conf':
|
|
|
|
ensure => present,
|
|
|
|
owner => 'root',
|
|
|
|
group => 'root',
|
|
|
|
mode => '0644',
|
|
|
|
source =>
|
|
|
|
'puppet:///modules/openstack_project/rsyslog.d_50-default.conf',
|
|
|
|
replace => true,
|
|
|
|
}
|
|
|
|
service { 'rsyslog':
|
|
|
|
ensure => running,
|
|
|
|
hasrestart => true,
|
|
|
|
subscribe => File['/etc/rsyslog.d/50-default.conf'],
|
|
|
|
}
|
2013-05-14 18:44:44 +00:00
|
|
|
|
|
|
|
# Ubuntu installs their whoopsie package by default, but it eats through
|
|
|
|
# memory and we don't need it on servers
|
|
|
|
package { 'whoopsie':
|
|
|
|
ensure => absent,
|
|
|
|
}
|
2013-02-20 04:12:13 +00:00
|
|
|
}
|
2012-07-20 18:56:35 -07:00
|
|
|
}
|