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

Safe HaskellNone




satellite :: PropertySource

Configures postfix as a satellite system, which relays all mail through a relay host, which defaults to smtp.domain.

The smarthost may refuse to relay mail on to other domains, without futher coniguration/keys. But this should be enough to get cron job mail flowing to a place where it will be seen.

mappedFile :: FilePath -> (FilePath -> Property) -> PropertySource

Sets up a file by running a property (which the filename is passed to). If the setup property makes a change, postmap will be run on the file, and postfix will be reloaded.

newaliases :: PropertySource

Run newaliases command, which should be done after changing etcaliases.

mainCfFile :: FilePathSource

The main config file for postfix.

mainCf :: (String, String) -> PropertySource

Sets a name=value pair. Does not reload postfix immediately.

getMainCf :: String -> IO (Maybe String)Source

Gets a setting.

mainCfIsSet :: String -> IO BoolSource

dedupMainCf :: PropertySource

Parses, and removes any initial configuration lines that are overridden to other values later in the file.

For example, to add some settings, removing any old settings:

 mainCf `File.containsLines`
	[ "# I like bars."
	, "foo = bar"
	] `onChange` dedupMainCf

Note that multiline configurations that continue onto the next line are not currently supported.

dedupCf :: [String] -> [String]Source