+ $ftpsite = $name
+
+ $fname = "/etc/vsftpd-${name}.conf"
+
+ file { $fname:
+ ensure => $ensure,
+ content => template('vsftpd/vsftpd.conf.erb'),
+ owner => 'root',
+ group => 'root',
+ mode => '0444',
+ }
+
+ file { "/etc/logrotate.d/vsftpd-${name}":
+ ensure => absent
+ }
+
+ file { "/etc/systemd/system/vsftpd-${name}@.service":
+ ensure => $ensure,
+ content => template('vsftpd/systemd-vsftpd.service.erb'),
+ owner => 'root',
+ group => 'root',
+ mode => '0444',
+ require => File[$fname],
+ notify => Exec['systemctl daemon-reload'],
+ }
+
+ file { "/etc/systemd/system/vsftpd-${name}.socket":
+ ensure => $ensure,
+ content => template('vsftpd/systemd-vsftpd.socket.erb'),
+ owner => 'root',
+ group => 'root',
+ mode => '0444',
+ notify => [
+ Exec['systemctl daemon-reload'],
+ Service["vsftpd-${name}.socket"],
+ ],
+ }
+
+ service { "vsftpd-${name}.socket":
+ ensure => $ensure_service,
+ enable => $ensure_enable,
+ require => [
+ Exec['systemctl daemon-reload'],
+ File["/etc/systemd/system/vsftpd-${name}@.service"],
+ File["/etc/systemd/system/vsftpd-${name}.socket"],
+ ],
+ provider => systemd,
+ }
+
+ munin::check { "vsftpd-${name}":
+ ensure => $ensure,
+ script => 'vsftpd'
+ }
+ munin::conf { "vsftpd-${name}":
+ ensure => $ensure,
+ content => template('vsftpd/munin.erb')
+ }