From bbc4a84f4f905fa8fcc382ab3425f4c3f62add9c Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Wed, 2 Apr 2014 13:28:46 -0400 Subject: always clear the provisioned flag --- Propellor/Property/Docker.hs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'Propellor/Property/Docker.hs') diff --git a/Propellor/Property/Docker.hs b/Propellor/Property/Docker.hs index 3f90d157..0cec9e1e 100644 --- a/Propellor/Property/Docker.hs +++ b/Propellor/Property/Docker.hs @@ -230,14 +230,12 @@ runningContainer cid@(ContainerId hn cn) image containerprops = containerDesc ci if (ident2id <$> runningident) == Just (ident2id ident) then return NoChange else do - clearProvisionedFlag cid void $ stopContainer cid oldimage <- fromMaybe image <$> commitContainer cid void $ removeContainer cid go oldimage else do whenM (elem cid <$> listContainers AllContainers) $ do - clearProvisionedFlag cid void $ removeContainer cid go image where @@ -258,6 +256,7 @@ runningContainer cid@(ContainerId hn cn) image containerprops = containerDesc ci chaincmd = [localdir "propellor", "--docker", fromContainerId cid] go img = do + clearProvisionedFlag cid createDirectoryIfMissing True (takeDirectory $ identFile cid) writeFile (identFile cid) (show ident) ifM (runContainer img (runps ++ ["-i", "-d", "-t"]) chaincmd) -- cgit v1.2.3