summaryrefslogtreecommitdiff
path: root/src/Propellor/Property/Postfix.hs
diff options
context:
space:
mode:
authorJoey Hess2015-12-06 14:24:44 -0400
committerJoey Hess2015-12-06 14:24:44 -0400
commit030f13f2d0501c9fb42c8f1efa0a15fa63c94d67 (patch)
treef81cbf9524d258daea72ab09866a6a8fe526c827 /src/Propellor/Property/Postfix.hs
parent94f91a44810dc3a1eca95c843e3c444cbbe87006 (diff)
allow using `check` on a UncheckedProperty, which yields a Property
Diffstat (limited to 'src/Propellor/Property/Postfix.hs')
-rw-r--r--src/Propellor/Property/Postfix.hs7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/Propellor/Property/Postfix.hs b/src/Propellor/Property/Postfix.hs
index e9fdfc38..1c8684c7 100644
--- a/src/Propellor/Property/Postfix.hs
+++ b/src/Propellor/Property/Postfix.hs
@@ -60,9 +60,8 @@ mappedFile f setup = setup f
-- | Run newaliases command, which should be done after changing
-- @/etc/aliases@.
newaliases :: Property NoInfo
-newaliases = check ("/etc/aliases" `isNewerThan` "/etc/aliases.db") $
- cmdProperty "newaliases" []
- `assume` MadeChange
+newaliases = check ("/etc/aliases" `isNewerThan` "/etc/aliases.db")
+ (cmdProperty "newaliases" [])
-- | The main config file for postfix.
mainCfFile :: FilePath
@@ -76,7 +75,6 @@ mainCf (name, value) = check notset set
setting = name ++ "=" ++ value
notset = (/= Just value) <$> getMainCf name
set = cmdProperty "postconf" ["-e", setting]
- `assume` MadeChange
-- | Gets a main.cf setting.
getMainCf :: String -> IO (Maybe String)
@@ -162,7 +160,6 @@ saslAuthdInstalled = setupdaemon
dirperm = check (not <$> doesDirectoryExist dir) $
cmdProperty "dpkg-statoverride"
[ "--add", "root", "sasl", "710", dir ]
- `assume` MadeChange
postfixgroup = (User "postfix") `User.hasGroup` (Group "sasl")
`onChange` restarted
dir = "/var/spool/postfix/var/run/saslauthd"