fix chroot info propigation

This commit is contained in:
Joey Hess 2014-11-20 16:04:48 -04:00
parent a4f04fcb02
commit 2293b46bf7
2 changed files with 6 additions and 3 deletions

1
debian/changelog vendored
View File

@ -19,6 +19,7 @@ propellor (1.0.0) UNRELEASED; urgency=medium
in the main host list, and are instead passed to
Docker.docked. (API change)
* Added support for using debootstrap from propellor.
* Propellor can now be used to provision chroots.
-- Joey Hess <id@joeyh.name> Mon, 10 Nov 2014 11:15:27 -0400

View File

@ -53,9 +53,11 @@ provisioned c@(Chroot loc system _) = RevertableProperty
teardown = undefined
propigateChrootInfo :: Chroot -> Property -> Property
propigateChrootInfo c@(Chroot loc _ h) p = propigateInfo c p (<> chrootinfo)
where
chrootinfo = mempty $ mempty { _chroots = M.singleton loc h }
propigateChrootInfo c p = propigateInfo c p (<> chrootInfo c)
chrootInfo :: Chroot -> Info
chrootInfo (Chroot loc _ h) =
mempty { _chrootinfo = mempty { _chroots = M.singleton loc h } }
-- | Propellor is run inside the chroot to provision it.
--