summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--provider_base/services/tor.json4
-rw-r--r--puppet/modules/site_tor/manifests/init.pp3
2 files changed, 5 insertions, 2 deletions
diff --git a/provider_base/services/tor.json b/provider_base/services/tor.json
index ae4da46d..7d9c6d34 100644
--- a/provider_base/services/tor.json
+++ b/provider_base/services/tor.json
@@ -1,6 +1,8 @@
{
"tor": {
"bandwidth_rate": 6550,
- "contacts": "= [provider.contacts['tor'] || provider.contacts.default].flatten"
+ "contacts": "= [provider.contacts['tor'] || provider.contacts.default].flatten",
+ "nickname": "= (self.name + secret(:tor_family)).sub('_','')[0..18]",
+ "family": "= nodes[:service => 'tor'].field('tor.nickname').join(',')"
}
}
diff --git a/puppet/modules/site_tor/manifests/init.pp b/puppet/modules/site_tor/manifests/init.pp
index 02368a0e..e62cb12d 100644
--- a/puppet/modules/site_tor/manifests/init.pp
+++ b/puppet/modules/site_tor/manifests/init.pp
@@ -7,6 +7,7 @@ class site_tor {
$tor_type = $tor['type']
$nickname = $tor['nickname']
$contact_emails = join($tor['contacts'],', ')
+ $family = $tor['family']
$address = hiera('ip_address')
@@ -16,7 +17,7 @@ class site_tor {
address => $address,
contact_info => obfuscate_email($contact_emails),
bandwidth_rate => $bandwidth_rate,
- my_family => '$2A431444756B0E7228A7918C85A8DACFF7E3B050',
+ my_family => $family
}
if ( $tor_type == 'exit'){