|
Puppetmodule
- mount.pp
#class { 'profile::linux::config::mountmyrep': arg => present,}
#/etc/puppet/modules/profile/manifests/linux/config/mountmyrep.pp
class profile::linux::config::mountmyrep ($arg = 'absent',){
$mntdir = '/mnt/myrep'
file { "$mntdir" :
ensure => 'directory',
}
mount { "$mntdir" :
device => "myrepsrv:/linuxrepos/www/suse",
fstype => "nfs",
ensure => $arg,
options => "defaults",
atboot => true,
remounts => true,
require => file["$mntdir"],
}
exec {'mount -a':
path => ["/usr/bin","/usr/sbin", "/bin"],
require => mount["$mntdir"],
}
}
- cert.pp
#/etc/puppet/modules/profile/manifests/linux/config/cert.pp
#class { 'profile::linux::config::cert': arg => 'http://myrep/certs/myCA.pem'
class profile::linux::config::cert ($arg = '',){
$buf = basename($arg)
include ca_cert
ca_cert::ca { $buf :
ensure => present,
source => $arg,
}
}
- dnscfg.pp
#/etc/puppet/modules/profile/manifests/linux/config/dnscfg.pp
#class { 'profile::linux::config::dnscfg': arg => 'my.second.dom.ain',}
class profile::linux::config::dnscfg ($arg = 'my.dom.ain',){
case $arg {
'mydom.ain': { $mynameservers = ['10.10.10.241', '10.10.10.246']}
default:{ $mynameservers = ['192.168.1.2', '192.168.1.3', '192.168.1.4']}
}
class { 'resolv_conf':
domainname => $arg,
nameservers => $mynameservers,
}
}
- rsyslog.pp
#/etc/puppet/modules/profile/manifests/linux/config/rsyslog.pp
#class { 'profile::linux::config::rsyslog': arg => 'myrsyslog2.my.dom.ain',}
class profile::linux::config::rsyslog ($arg = 'mysyslog1.my.dom.ain',){
class { 'rsyslog::client':
log_remote => true,
server => $arg,
}
}
- exim4d.pp
#/etc/puppet/modules/profile/manifests/linux/service/exim4d.pp
#class { 'profile::linux::service::exim4d': arg => 'mysmtp2.my.dom.ain',}
class profile::linux::service::exim4d ($arg ='mysmtsrv',) {
class { '::eximsimple':
smarthost => $arg,
root => "root@$::fqdn",
domain => $::domain,
}
}
- ntpd.pp
#/etc/puppet/environments/it/modules/profile/manifests/linux/service/ntpd.pp
##include '::ntp'
#class { 'profile::linux::service::ntpd': arg => ['time1','time2'],}
class profile::linux::service::ntpd ($arg = ['timesrv1','timesrv2']) {
class { '::ntp':
servers => $arg,
}
}
- snmpd.pp
#/etc/puppet/modules/profile/manifests/linux/service/snmpdd.pp
#class { 'profile::linux::service::snmpd': arg => 'MysecretCommunity',}
class profile::linux::service::snmpd ($arg ='public',) {
class { '::snmp':
ro_community => $arg,
ro_network => '10.11.12.0/24',
agentaddress => ['udp:161'],
contact => 'snmpd@my.domain',
location => 'im RZ',
# views => ['disk / 10000'],
views => ['all included .iso'],
services => 72,
}
}
|
|