summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--debian/changelog6
-rw-r--r--joeyconfig.hs2
-rw-r--r--src/Propellor/Property/Tor.hs6
3 files changed, 11 insertions, 3 deletions
diff --git a/debian/changelog b/debian/changelog
index 893498a4..e01f4a20 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+propellor (3.2.0) UNRELEASED; urgency=medium
+
+ * Tor.hiddenService: Converted port parameter from Int to Port. (API change)
+
+ -- Joey Hess <id@joeyh.name> Thu, 01 Sep 2016 10:30:17 -0400
+
propellor (3.1.1) unstable; urgency=medium
* Haddock build fix.
diff --git a/joeyconfig.hs b/joeyconfig.hs
index fa37e97b..67398048 100644
--- a/joeyconfig.hs
+++ b/joeyconfig.hs
@@ -483,6 +483,8 @@ keysafe = host "keysafe.joeyh.name" $ props
& Ssh.noPasswords
& Tor.installed
+ & Tor.hiddenServiceAvailable "keysafe" (Port 4242)
+ `requires` Tor.hiddenServiceData "keysafe" hostContext
-- keysafe installed manually until package is available
iabak :: Host
diff --git a/src/Propellor/Property/Tor.hs b/src/Propellor/Property/Tor.hs
index 92dbd507..fb756f56 100644
--- a/src/Propellor/Property/Tor.hs
+++ b/src/Propellor/Property/Tor.hs
@@ -119,7 +119,7 @@ bandwidthRate' s divby = case readSize dataUnits s of
`describe` ("tor BandwidthRate " ++ v)
Nothing -> property ("unable to parse " ++ s) noChange
-hiddenServiceAvailable :: HiddenServiceName -> Int -> Property DebianLike
+hiddenServiceAvailable :: HiddenServiceName -> Port -> Property DebianLike
hiddenServiceAvailable hn port = hiddenServiceHostName $ hiddenService hn port
where
hiddenServiceHostName p = adjustPropertySatisfy p $ \satisfy -> do
@@ -128,8 +128,8 @@ hiddenServiceAvailable hn port = hiddenServiceHostName $ hiddenService hn port
warningMessage $ unwords ["hidden service hostname:", h]
return r
-hiddenService :: HiddenServiceName -> Int -> Property DebianLike
-hiddenService hn port = ConfFile.adjustSection
+hiddenService :: HiddenServiceName -> Port -> Property DebianLike
+hiddenService hn (Port port) = ConfFile.adjustSection
(unwords ["hidden service", hn, "available on port", show port])
(== oniondir)
(not . isPrefixOf "HiddenServicePort")