summaryrefslogtreecommitdiff
path: root/src/Propellor/Property/Docker.hs
diff options
context:
space:
mode:
authorJoey Hess2014-05-31 21:18:36 -0400
committerJoey Hess2014-05-31 21:18:36 -0400
commit7c4b1537391d801855e28a61c896efcc70cfaa81 (patch)
tree010b433c4f9eae6f0336ad0735f2893cf0a7498e /src/Propellor/Property/Docker.hs
parentd1eafb12776d6487ecd48d3991838032a81181d6 (diff)
simplify monoid instance with some helper types
Diffstat (limited to 'src/Propellor/Property/Docker.hs')
-rw-r--r--src/Propellor/Property/Docker.hs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Propellor/Property/Docker.hs b/src/Propellor/Property/Docker.hs
index 8e081ae4..ce10d318 100644
--- a/src/Propellor/Property/Docker.hs
+++ b/src/Propellor/Property/Docker.hs
@@ -48,7 +48,7 @@ type ContainerName = String
container :: ContainerName -> Image -> Host
container cn image = Host hn [] attr
where
- attr = mempty { _dockerImage = Just image }
+ attr = mempty { _dockerImage = Val image }
hn = cn2hn cn
cn2hn :: ContainerName -> HostName
@@ -116,7 +116,7 @@ findContainer mhost cid cn mk = case mhost of
mkContainer :: ContainerId -> Host -> Maybe Container
mkContainer cid@(ContainerId hn _cn) h = Container
- <$> _dockerImage attr
+ <$> fromVal (_dockerImage attr)
<*> pure (map (\a -> a hn) (_dockerRunParams attr))
where
attr = hostAttr h'