diff options
Diffstat (limited to 'manifests/faillog')
-rw-r--r-- | manifests/faillog/disable.pp | 7 | ||||
-rw-r--r-- | manifests/faillog/enable.pp | 11 |
2 files changed, 10 insertions, 8 deletions
diff --git a/manifests/faillog/disable.pp b/manifests/faillog/disable.pp index c05e6bc..4e1df4e 100644 --- a/manifests/faillog/disable.pp +++ b/manifests/faillog/disable.pp @@ -1,9 +1,10 @@ +# do not log any faillog class loginrecords::faillog::disable inherits loginrecords::faillog::enable{ Replace['loginrecords-faillog']{ - pattern => '^FAILLOG_ENAB[[:space:]]+yes$', - replacement => 'FAILLOG_ENAB no', + pattern => '^FAILLOG_ENAB[[:space:]]+yes$', + replacement => "FAILLOG_ENAB\tno", } Line['loginrecords-faillog']{ - line => 'FAILLOG_ENAB no', + line => "FAILLOG_ENAB\tno", } } diff --git a/manifests/faillog/enable.pp b/manifests/faillog/enable.pp index c714b74..d600f6f 100644 --- a/manifests/faillog/enable.pp +++ b/manifests/faillog/enable.pp @@ -1,14 +1,15 @@ +# manage faillog logging class loginrecords::faillog::enable( $login_defs_file = '/etc/login.defs' ) { replace{'loginrecords-faillog': - file => $login_defs_file, - pattern => '^FAILLOG_ENAB[[:space]]+no$', - replacement => 'FAILLOG_ENAB yes', + file => $loginrecords::faillog::enable::login_defs_file, + pattern => '^FAILLOG_ENAB[[:space]]+no$', + replacement => "FAILLOG_ENAB\tyes", } line{'loginrecords-faillog': - file => $login_defs_file, - line => 'FAILLOG_ENAB yes', + file => $loginrecords::faillog::enable::login_defs_file, + line => "FAILLOG_ENAB\tyes", require => Replace['loginrecords-faillog'], } } |