propellor-3.2.3: property-based host configuration management in haskell

Safe HaskellNone
LanguageHaskell98

Propellor.Types.Info

Synopsis

Documentation

data Info Source #

Information about a Host, which can be provided by its properties.

Many different types of data can be contained in the same Info value at the same time. See toInfo and fromInfo.

Instances

Show Info Source # 

Methods

showsPrec :: Int -> Info -> ShowS

show :: Info -> String

showList :: [Info] -> ShowS

Monoid Info Source # 

Methods

mempty :: Info

mappend :: Info -> Info -> Info

mconcat :: [Info] -> Info

class (Typeable v, Monoid v, Show v) => IsInfo v where Source #

Values stored in Info must be members of this class.

This is used to avoid accidentially using other data types as info, especially type aliases which coud easily lead to bugs. We want a little bit of dynamic types here, but not too far..

Minimal complete definition

propagateInfo

Methods

propagateInfo :: v -> Bool Source #

Should info of this type be propagated out of a container to its Host?

Instances

IsInfo NamedConfMap Source # 
IsInfo DnsInfo Source #

DNS Info is propagated, so that eg, aliases of a container are reflected in the dns for the host where it runs.

Methods

propagateInfo :: DnsInfo -> Bool Source #

IsInfo AliasesInfo Source # 

Methods

propagateInfo :: AliasesInfo -> Bool Source #

IsInfo ChrootInfo Source # 

Methods

propagateInfo :: ChrootInfo -> Bool Source #

IsInfo DockerInfo Source # 

Methods

propagateInfo :: DockerInfo -> Bool Source #

IsInfo PrivInfo Source # 

Methods

propagateInfo :: PrivInfo -> Bool Source #

IsInfo PkgUpgrade Source # 

Methods

propagateInfo :: PkgUpgrade -> Bool Source #

IsInfo PkgUpdate Source # 

Methods

propagateInfo :: PkgUpdate -> Bool Source #

IsInfo PoudriereConfigured Source # 
(Typeable * v, Show v) => IsInfo (InfoVal v) Source # 

Methods

propagateInfo :: InfoVal v -> Bool Source #

addInfo :: IsInfo v => Info -> v -> Info Source #

Any value in the IsInfo type class can be added to an Info.

toInfo :: IsInfo v => v -> Info Source #

Converts any value in the IsInfo type class into an Info, which is otherwise empty.

fromInfo :: IsInfo v => Info -> v Source #

mapInfo :: IsInfo v => (v -> v) -> Info -> Info Source #

Maps a function over all values stored in the Info that are of the appropriate type.

propagatableInfo :: Info -> Info Source #

Filters out parts of the Info that should not propagate out of a container.

data InfoVal v Source #

Use this to put a value in Info that is not a monoid. The last value set will be used. This info does not propagate out of a container.

Constructors

NoInfoVal 
InfoVal v 

Instances

Show v => Show (InfoVal v) Source # 

Methods

showsPrec :: Int -> InfoVal v -> ShowS

show :: InfoVal v -> String

showList :: [InfoVal v] -> ShowS

Monoid (InfoVal v) Source # 

Methods

mempty :: InfoVal v

mappend :: InfoVal v -> InfoVal v -> InfoVal v

mconcat :: [InfoVal v] -> InfoVal v

(Typeable * v, Show v) => IsInfo (InfoVal v) Source # 

Methods

propagateInfo :: InfoVal v -> Bool Source #

fromInfoVal :: InfoVal v -> Maybe v Source #

class Typeable k a #

Minimal complete definition

typeRep#