From 9e55e18c84259bb007fa023c9e06b908e8f042a2 Mon Sep 17 00:00:00 2001 From: Nan Liu Date: Fri, 27 Jul 2012 16:01:33 -0700 Subject: Fix whitespace and readme. --- README.md | 2 +- manifests/init.pp | 21 +++++++++++---------- manifests/params.pp | 1 - 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/README.md b/README.md index ae99176..57097de 100644 --- a/README.md +++ b/README.md @@ -17,7 +17,7 @@ Parameters: * address: bind address, default 0.0.0.0. * port: bind port, default 69. * options: service option, default --secure. -* inetd: run service via xinetd - default true +* inetd: run service via xinetd - default false. Example: diff --git a/manifests/init.pp b/manifests/init.pp index 8becd7d..4fe22be 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -39,20 +39,20 @@ class tftp ( ensure => present, name => $package, } + if $defaults { - file { '/etc/default/tftpd-hpa': - ensure => file, - owner => 'root', - group => 'root', - mode => '0644', - content => template('tftp/tftpd-hpa.erb'), - require => Package['tftpd-hpa'], + file { '/etc/default/tftpd-hpa': + ensure => file, + owner => 'root', + group => 'root', + mode => '0644', + content => template('tftp/tftpd-hpa.erb'), + require => Package['tftpd-hpa'], notify => Service['tftpd-hpa'], - } + } } if $inetd { - include 'xinetd' xinetd::service { 'tftp': @@ -67,7 +67,8 @@ class tftp ( flags => 'IPv4', per_source => '11', wait => 'yes', - } + } + $svc_ensure = stopped $svc_enable = false } else { diff --git a/manifests/params.pp b/manifests/params.pp index 93344b7..bbe86cc 100644 --- a/manifests/params.pp +++ b/manifests/params.pp @@ -43,5 +43,4 @@ class tftp::params { warning("tftp:: $::operatingsystem may not be supported") } } - } -- cgit v1.2.3