diff options
| author | Joey Hess <joeyh@joeyh.name> | 2015-09-06 08:19:02 -0700 |
|---|---|---|
| committer | Joey Hess <joeyh@joeyh.name> | 2015-09-06 16:13:54 -0400 |
| commit | def53b64cc17b95eb5729dd97a800dfe1257b352 (patch) | |
| tree | 03f63e5bcb6486b00639e1ea78c21d8928c3b8ca /src/Propellor/PropAccum.hs | |
| parent | 6f4024f5307a81f26f5e6bf86b84c7363219cb3d (diff) | |
Added Propellor.Property.Rsync. WIP; untested
Convert Info to use Data.Dynamic, so properties can export and consume
info of any type that is Typeable and a Monoid, including data types
private to a module. (API change)
Thanks to Joachim Breitner for the idea.
Diffstat (limited to 'src/Propellor/PropAccum.hs')
| -rw-r--r-- | src/Propellor/PropAccum.hs | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/src/Propellor/PropAccum.hs b/src/Propellor/PropAccum.hs index 20d083cb..d2736b50 100644 --- a/src/Propellor/PropAccum.hs +++ b/src/Propellor/PropAccum.hs @@ -13,6 +13,7 @@ import Data.Monoid import Propellor.Types import Propellor.Property +import Propellor.Types.Info -- | Starts accumulating the properties of a Host. -- @@ -71,12 +72,6 @@ infixl 1 ! -- -- The Info of the propertyChildren is adjusted to only include -- info that should be propigated out to the Property. --- --- DNS Info is propigated, so that eg, aliases of a PropAccum --- are reflected in the dns for the host where it runs. --- --- PrivData Info is propigated, so that properties used inside a --- PropAccum will have the necessary PrivData available. propigateContainer :: (PropAccum container) => container @@ -90,10 +85,6 @@ propigateContainer c prop = infoProperty where hostprops = map go $ getProperties c go p = - let i = propertyInfo p - i' = mempty - { _dns = _dns i - , _privData = _privData i - } + let i = propigatableInfo (propertyInfo p) cs = map go (propertyChildren p) - in infoProperty (propertyDesc p) (propertySatisfy p) i' cs + in infoProperty (propertyDesc p) (propertySatisfy p) i cs |
