From d1425be30a1fcd45659c67c74ba2121e1be683d0 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Thu, 27 Nov 2014 11:49:23 -0400 Subject: propellor spin --- config-joey.hs | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/config-joey.hs b/config-joey.hs index 67986ffe..d67fc8a2 100644 --- a/config-joey.hs +++ b/config-joey.hs @@ -24,9 +24,10 @@ import qualified Propellor.Property.Postfix as Postfix import qualified Propellor.Property.Grub as Grub import qualified Propellor.Property.Obnam as Obnam import qualified Propellor.Property.Gpg as Gpg -import qualified Propellor.Property.Chroot as Chroot import qualified Propellor.Property.Systemd as Systemd +import qualified Propellor.Property.Chroot as Chroot import qualified Propellor.Property.Debootstrap as Debootstrap +import qualified Propellor.Property.OS as OS import qualified Propellor.Property.HostingProvider.DigitalOcean as DigitalOcean import qualified Propellor.Property.HostingProvider.CloudAtCost as CloudAtCost import qualified Propellor.Property.HostingProvider.Linode as Linode @@ -48,8 +49,17 @@ hosts = -- (o) ` , diatom , elephant , alien + , testvm ] ++ monsters +testvm :: Host +testvm = host "testvm.kitenet.net" + & Chroot.provisioned (Chroot.debootstrapped (System (Debian Unstable) "amd64") Debootstrap.DefaultConfig "/new-os") + -- & OS.cleanInstall (OS.Confirmed "foo.example.com") [] + -- `onChange` propertyList "fixing up after clean install" + -- [ + -- ] + darkstar :: Host darkstar = host "darkstar.kitenet.net" & ipv6 "2001:4830:1600:187::2" -- sixxs tunnel -- cgit v1.2.3 From 7ddb862176764fb52ab64d3c746f3841b1a3ba65 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Thu, 27 Nov 2014 17:51:41 -0400 Subject: propellor spin --- src/Propellor/Engine.hs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/Propellor/Engine.hs b/src/Propellor/Engine.hs index 0b65fb7e..b0b1695a 100644 --- a/src/Propellor/Engine.hs +++ b/src/Propellor/Engine.hs @@ -77,6 +77,7 @@ processChainOutput h = go Nothing where go lastline = do v <- catchMaybeIO (hGetLine h) + debug ["read from chained propellor: ", show v] case v of Nothing -> case lastline of Nothing -> pure FailedChange -- cgit v1.2.3 From 9500e9bb810202eabc6a299ca8aa3a70fa5dcee6 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Thu, 27 Nov 2014 17:55:56 -0400 Subject: added more debugging --- src/Propellor/Engine.hs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/Propellor/Engine.hs b/src/Propellor/Engine.hs index b0b1695a..81cc2397 100644 --- a/src/Propellor/Engine.hs +++ b/src/Propellor/Engine.hs @@ -80,10 +80,13 @@ processChainOutput h = go Nothing debug ["read from chained propellor: ", show v] case v of Nothing -> case lastline of - Nothing -> pure FailedChange + Nothing -> do + debug ["chained propellor output nothing; assuming it failed"] + return FailedChange Just l -> case readish l of Just r -> pure r Nothing -> do + debug ["chained propellor output did not end with a Result; assuming it failed"] putStrLn l hFlush stdout return FailedChange -- cgit v1.2.3 From 4c2eac2d3c5a190fe727fca39e71e7218fba940a Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Thu, 27 Nov 2014 19:10:39 -0400 Subject: remove -i, seems not needed and may be causing problem --- src/Propellor/Property/Docker.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Propellor/Property/Docker.hs b/src/Propellor/Property/Docker.hs index 586ebc2e..5fa06517 100644 --- a/src/Propellor/Property/Docker.hs +++ b/src/Propellor/Property/Docker.hs @@ -430,7 +430,7 @@ provisionContainer cid = containerDesc cid $ property "provisioned" $ liftIO $ d let params = ["--continue", show $ toChain cid] msgh <- mkMessageHandle let p = inContainerProcess cid - [ if isConsole msgh then "-it" else "-i" ] + (if isConsole msgh then ["-it"] else []) (shim : params) r <- withHandle StdoutHandle createProcessSuccess p $ processChainOutput -- cgit v1.2.3 From 1906500030b1f2692d9abe46c2368338d9163894 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Fri, 28 Nov 2014 11:40:03 -0400 Subject: switch kite to testing --- config-joey.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config-joey.hs b/config-joey.hs index d67fc8a2..b617ccfa 100644 --- a/config-joey.hs +++ b/config-joey.hs @@ -130,7 +130,7 @@ orca = standardSystem "orca.kitenet.net" Unstable "amd64" -- multiuser system with eg, user passwords that are not deployed -- with propellor. kite :: Host -kite = standardSystemUnhardened "kite.kitenet.net" Unstable "amd64" +kite = standardSystemUnhardened "kite.kitenet.net" Testing "amd64" [ "Welcome to the new kitenet.net server!" ] & ipv4 "66.228.36.95" -- cgit v1.2.3