summaryrefslogtreecommitdiff
path: root/src/Propellor/Property/OS.hs
diff options
context:
space:
mode:
Diffstat (limited to 'src/Propellor/Property/OS.hs')
-rw-r--r--src/Propellor/Property/OS.hs8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/Propellor/Property/OS.hs b/src/Propellor/Property/OS.hs
index e84490fd..2185471d 100644
--- a/src/Propellor/Property/OS.hs
+++ b/src/Propellor/Property/OS.hs
@@ -11,6 +11,7 @@ import Propellor
import qualified Propellor.Property.Debootstrap as Debootstrap
import qualified Propellor.Property.Ssh as Ssh
import qualified Propellor.Property.File as File
+import qualified Propellor.Property.Reboot as Reboot
import Propellor.Property.Mount
import Propellor.Property.Chroot.Util (stdPATH)
import Utility.SafeCommand
@@ -67,6 +68,8 @@ cleanInstallOnce confirmation = check (not <$> doesFileExist flagfile) $
go =
finalized
`requires`
+ Reboot.atEnd True (/= FailedChange)
+ `requires`
propellorbootstrapped
`requires`
flipped
@@ -137,11 +140,6 @@ cleanInstallOnce confirmation = check (not <$> doesFileExist flagfile) $
finalized = property "clean OS installed" $ do
liftIO $ writeFile flagfile ""
- endAction "rebooting into new OS" $ liftIO $
- ifM (boolSystem "reboot" [ Param "--force" ])
- ( return MadeChange
- , return FailedChange
- )
return MadeChange
flagfile = "/etc/propellor-cleaninstall"