]> gitweb.fluxo.info Git - puppet-apache.git/commitdiff
Declaring docroot folders as virtual resources
authorSilvio Rhatto <rhatto@riseup.net>
Sun, 8 Nov 2009 15:40:44 +0000 (13:40 -0200)
committerSilvio Rhatto <rhatto@riseup.net>
Sun, 8 Nov 2009 15:40:44 +0000 (13:40 -0200)
manifests/init.pp

index 0a72f801c718fb53930d51dfd76ff2de9a4df4cf..287b2f5ec00dfc1ee958022f535720cad462d3ad 100644 (file)
@@ -108,11 +108,12 @@ class apache {
                   && [ ${apache2_sites}-enabled/$name -ef ${apache2_sites}-available/$name ]'",
           notify  => Exec["reload-apache2"],
         }
-        file { "${docroot}":
+        @file { "${docroot}":
           ensure => directory,
           owner  => root,
           group  => root,
           mode   => 0755,
+          tag    => "apache_docroot",
         }
       }
       'absent': {
@@ -165,4 +166,7 @@ class apache {
     command     => "/etc/init.d/apache2 force-reload",
     refreshonly => true,
   }
+
+  # Realize all docroot resources
+  File <| tag == "apache_docroot" |>
 }