use proper directory
[mirror/dsa-puppet.git] / modules / onion / manifests / service.pp
index b025f67..80d6922 100644 (file)
@@ -29,7 +29,7 @@ define onion::service (
 
                        if ($direct) {
                                @@concat::fragment { "onion::balance::onionbalance-services.yaml::${name}":
-                                       target  => "/srv/puppet.torproject.org/puppet-facts/onionbalance-services.yaml",
+                                       target  => "/srv/puppet.debian.org/puppet-facts/onionbalance-services.yaml",
                                        content => "{\"${name}\": \"${onion_hn}\"}\n",
                                        tag     => "onionbalance-services.yaml",
                                }
@@ -41,5 +41,12 @@ define onion::service (
                                }
                        }
                }
+       } elsif ($my_ensure == "absent") {
+               file { "/var/lib/tor/onion/${name}":
+                       ensure => absent,
+                       force  => true,
+               }
+       } else {
+               fail("Invalid ensure value ${my_ensure}")
        }
 }