summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2012-06-10 17:02:30 -0300
committerSilvio Rhatto <rhatto@riseup.net>2012-06-10 17:02:30 -0300
commit0bf23285977ffdf60f7151949651a62fb93f2552 (patch)
treebd026e60e8e069719605a2ce0051436cf995cb0f
parent7bf57976706f73881d18bbaea0e7f87b7f1c3b40 (diff)
Managing the top level folder of a hidden service
-rw-r--r--manifests/daemon.pp9
1 files changed, 9 insertions, 0 deletions
diff --git a/manifests/daemon.pp b/manifests/daemon.pp
index 6d8c315..9c00e9a 100644
--- a/manifests/daemon.pp
+++ b/manifests/daemon.pp
@@ -142,6 +142,15 @@ class tor::daemon inherits tor {
$data_dir = $tor::daemon::data_dir,
$ensure = present ) {
+ if !defined(File["$data_dir/.."]) {
+ file { "$data_dir/..":
+ ensure => present,
+ owner => 'debian-tor',
+ group => 'debian-tor',
+ mode => 0640,
+ }
+ }
+
concatenated_file_part { "05.hidden_service.${name}":
dir => $tor::daemon::snippet_dir,
content => template('tor/torrc.hidden_service.erb'),