diff options
Diffstat (limited to 'manifests/init.pp')
-rw-r--r-- | manifests/init.pp | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/manifests/init.pp b/manifests/init.pp new file mode 100644 index 0000000..0a38297 --- /dev/null +++ b/manifests/init.pp @@ -0,0 +1,38 @@ +# Class: tftp +# +# Parameters: +# +# Actions: +# +# Requires: +# +# Usage: +# +class tftp ( + $username = $tftp::params::username, + $directory = $tftp::params::directory, + $address = $tftp::params::address, + $port = $tftp::params::port, + $options = $tftp::params::options +) inherits tftp::params { + package { 'tftpd-hpa': + ensure => present, + } + + file { '/etc/default/tftpd-hpa': + ensure => file, + owner => 'root', + group => 'root', + mode => '0644', + content => template('tftp/tftpd-hpa.erb'), + require => Package['tftpd-hpa'], + } + + service { 'tftpd-hpa': + ensure => running, + provider => $tftp::params::provider, + hasstatus => $tftp::params::hasstatus, + pattern => '/usr/sbin/in.tftpd', + subscribe => File['/etc/default/tftpd-hpa'], + } +} |