Signed-off-by: Stephen Gran <steve@lobefin.net>
owner => root,
group => www-data,
mode => '0640',
- noop => true,
}
file { '/var/log/dacs':
class vsftpd::nolisten inherits vsftpd {
- $noop = $::hostname ? {
- bizet => false,
- franck => false,
- gluck => false,
- lobos => false,
- kassia => false,
- klecker => false,
- ravel => false,
- saens => false,
- santoro => false,
- schein => false,
- steffani => false,
- villa => false,
- wieck => false,
- morricone => false,
- default => true
- }
-
Service['vsftpd'] {
ensure => stopped,
- noop => $noop,
}
Service['vsftpd']->Service['xinetd']
file { '/etc/vsftpd.conf':
- noop => $noop,
content => "listen=NO\n",
notify => Service['vsftpd']
}
$fname = "/etc/vsftpd-${name}.conf"
- $noop = $::hostname ? {
- bizet => false,
- franck => false,
- gluck => false,
- lobos => false,
- kassia => false,
- klecker => false,
- ravel => false,
- saens => false,
- santoro => false,
- schein => false,
- steffani => false,
- villa => false,
- wieck => false,
- morricone => false,
- default => true
- }
-
if $source {
file { $fname:
ensure => $ensure,
- noop => $noop,
source => $source,
}
} elsif $content {
file { $fname:
ensure => $ensure,
- noop => $noop,
content => $content,
}
} else {
class xinetd {
package { 'xinetd':
ensure => installed,
- noop => true,
}
service { 'xinetd':
ensure => running,
hasstatus => false,
pattern => '/usr/sbin/xinetd',
- noop => true,
require => Package['xinetd']
}
}
) {
include xinetd
- $noop = $::hostname ? {
- bizet => false,
- franck => false,
- gluck => false,
- lobos => false,
- kassia => false,
- klecker => false,
- ravel => false,
- saens => false,
- santoro => false,
- schein => false,
- steffani => false,
- villa => false,
- wieck => false,
- morricone => false,
- default => true
- }
-
case $ensure {
present,absent,file: {}
default: { fail("Invalid ensure for '$name'") }
file { "/etc/xinetd.d/${name}":
ensure => $ensure,
- noop => $noop,
content => template('xinetd/service.erb'),
notify => Service['xinetd'],
require => Package['xinetd'],