summaryrefslogtreecommitdiff
path: root/Propellor/Property
diff options
context:
space:
mode:
authorJoey Hess2014-04-04 15:07:51 -0400
committerJoey Hess2014-04-04 15:07:51 -0400
commit4d69d83def502b3a5c75b7145dbdd92ce18f3c6c (patch)
tree2a71c0b8837aa45a70d209b949c82811c7a7fcc2 /Propellor/Property
parent00b27119eeee67669688746e3a80347db9cf23ec (diff)
propellor spin
Diffstat (limited to 'Propellor/Property')
-rw-r--r--Propellor/Property/Docker.hs9
1 files changed, 3 insertions, 6 deletions
diff --git a/Propellor/Property/Docker.hs b/Propellor/Property/Docker.hs
index da9ac36d..149df756 100644
--- a/Propellor/Property/Docker.hs
+++ b/Propellor/Property/Docker.hs
@@ -231,7 +231,7 @@ runningContainer cid@(ContainerId hn cn) image containerprops = containerDesc ci
if runningident == Just ident
then return NoChange
else do
- print "container parameters changed"
+ debug ["container parameters changed"]
void $ stopContainer cid
oldimage <- fromMaybe image <$> commitContainer cid
void $ removeContainer cid
@@ -244,11 +244,8 @@ runningContainer cid@(ContainerId hn cn) image containerprops = containerDesc ci
ident = ContainerIdent image hn cn runps
getrunningident :: IO (Maybe ContainerIdent)
- getrunningident = simpleShClient (namedPipe cid) "cat" [propellorIdent] $ \vs -> do
- let l = (extractident) vs
- print l
- print vs
- return l
+ getrunningident = simpleShClient (namedPipe cid) "cat" [propellorIdent] $
+ return . extractident
extractident :: [Resp] -> Maybe ContainerIdent
extractident = headMaybe . catMaybes . map readish . catMaybes . map getStdout