From aa5a5c50db6a26eeaaca2d886a62e73ae359d4ce Mon Sep 17 00:00:00 2001 From: mh Date: Fri, 13 Jun 2008 19:03:48 +0000 Subject: merged with puzzle --- manifests/init.pp | 32 ++++++++++++++++++++++---------- 1 file changed, 22 insertions(+), 10 deletions(-) diff --git a/manifests/init.pp b/manifests/init.pp index 0e2f9fb..4b849f4 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -1,15 +1,21 @@ -####################################### +# # denyhosts module -# Puzzle ITC - haerry+puppet(at)puzzle.ch -# GPLv3 -# adapated by immerda project group -# admin+puppet(at)immerda.ch -# this module is used to configure the +# +# Copyright 2008, Puzzle ITC GmbH +# Marcel Härry haerry+puppet(at)puzzle.ch +# Simon Josi josi+puppet(at)puzzle.ch +# +# This program is free software; you can redistribute +# it and/or modify it under the terms of the GNU +# General Public License version 3 as published by +# the Free Software Foundation. +# +# This module is used to configure the # denyhosts script. -####################################### - +# # modules_dir { "denyhosts": } + class denyhosts { case $operatingsystem { gentoo: { include denyhosts::gentoo } @@ -30,18 +36,24 @@ class denyhosts::base { File["/var/lib/denyhosts/allowed-hosts"] ], } - file{"/etc/denyhosts.conf": + file{'/etc/denyhosts.conf': source => [ "puppet://$server/files/denyhosts/${fqdn}/denyhosts.conf", "puppet://$server/files/denyhosts/denyhosts.conf", "puppet://$server/denyhosts/denyhosts.conf" ], notify => Service[denyhosts], mode => 0600, owner => root, group => 0; } - file{"/var/lib/denyhosts/allowed-hosts": + + file{'/var/lib/denyhosts/': + ensure => directory, + owner => root, group => 0, mode => 0755; + } + file{'/var/lib/denyhosts/allowed-hosts': source => [ "puppet://$server/files/denyhosts/${fqdn}/allowed-hosts", "puppet://$server/files/denyhosts/allowed-hosts", "puppet://$server/denyhosts/allowed-hosts" ], notify => Service[denyhosts], + require => File['/var/lib/denyhosts/'], mode => 0600, owner => root, group => 0; } } -- cgit v1.2.3