]> gitweb.fluxo.info Git - puppet-nodo.git/commitdiff
Using virtual resources at websites::hosting
authorSilvio Rhatto <rhatto@riseup.net>
Tue, 29 Nov 2011 22:57:34 +0000 (20:57 -0200)
committerSilvio Rhatto <rhatto@riseup.net>
Tue, 29 Nov 2011 22:57:34 +0000 (20:57 -0200)
manifests/subsystems/websites.pp

index da037ed34276b57e518e9f0e5555fd2d560c55d3..2a84c53a08fbc25ab74cf89af0c9976ccd010716 100644 (file)
@@ -141,9 +141,26 @@ class websites::hosting inherits websites::setup {
   include pmwiki
   include apache::rails
 
-  apache::site { "images":
+  Apache::site       <| tag == $nodename or tag == 'all' or tag == undef |>
+  Database::instance <| tag == $nodename or tag == 'all' or tag == undef |>
+  Ikiwiki::instance  <| tag == $nodename or tag == 'all' or tag == undef |>
+
+  Apache::site <| tag != $nodename and tag != 'all' and tag != undef |> {
+    ensure => absent,
+  }
+
+  Database::instance <| tag != $nodename and tag != 'all' and tag != undef  |> {
+    ensure => absent,
+  }
+
+  Ikiwiki::instance <| tag != $nodename and tag != 'all' and tag != undef |> {
+    ensure => absent,
+  }
+
+  @apache::site { "images":
     docroot => "${apache_www_folder}/images",
     mpm     => false,
+    tag     => 'all',
   }
 }