]> gitweb.fluxo.info Git - puppet-apache.git/commitdiff
Better definition for docroot check
authorSilvio Rhatto <rhatto@riseup.net>
Sun, 8 Nov 2009 20:05:19 +0000 (18:05 -0200)
committerSilvio Rhatto <rhatto@riseup.net>
Sun, 8 Nov 2009 20:05:19 +0000 (18:05 -0200)
manifests/init.pp

index c0362ed123b80a55aab61e174ed4724836427ca8..0580042f5fca7904e74762999fd9b1bfc32eb289 100644 (file)
@@ -120,9 +120,10 @@ class apache {
             recurse => false,
           }
         }
-        if !defined(Exec["/bin/mkdir -p ${docroot}"]) {
+        if !defined(Exec["check_docroot_${docroot}"]) {
           # Ensure parent folder exist
           exec { "/bin/mkdir -p ${docroot}":
+            unless => "/bin/sh -c '[ -e ${docroot} ]'",
             before => File["${docroot}"], 
           }
         }