From e04f523b1744db8a97e530e8945ded4e2f046d6c Mon Sep 17 00:00:00 2001 From: Peter Palfrader Date: Thu, 28 Jul 2016 20:32:47 +0000 Subject: [PATCH] put an onion instance into a storedconf for onionbalance --- modules/onion/manifests/service.pp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/modules/onion/manifests/service.pp b/modules/onion/manifests/service.pp index 1bfdb8d95..57e723f90 100644 --- a/modules/onion/manifests/service.pp +++ b/modules/onion/manifests/service.pp @@ -10,4 +10,13 @@ define onion::service ( order => 10, content => "HiddenServiceDir /var/lib/tor/onion/${name}\nHiddenServicePort ${port} ${target_address}:${target_port}\n\n", } + + $onion_hn = onion_hostname($name) + if $onion_hn { + @@concat::fragment { "onion::balance::instance::$name::$hostname": + target => "/etc/onionbalance/config", + content => " - address: ${onion_hn}\n name: ${hostname}-${name}", + tag => "onion::balance::$name", + } + } } -- 2.20.1