| Safe Haskell | Safe-Infered |
|---|
Ganeti.Runtime
Description
Implementation of the runtime configuration details.
- data GanetiDaemon
- = GanetiMasterd
- | GanetiMetad
- | GanetiNoded
- | GanetiRapi
- | GanetiConfd
- | GanetiWConfd
- | GanetiKvmd
- | GanetiLuxid
- | GanetiMaintd
- | GanetiMond
- data MiscGroup
- data GanetiGroup
- data RuntimeEnts = RuntimeEnts {
- reUserToUid :: Map GanetiDaemon UserID
- reUidToUser :: Map UserID String
- reGroupToGid :: Map GanetiGroup GroupID
- reGidToGroup :: Map GroupID String
- daemonName :: GanetiDaemon -> String
- daemonOnlyOnMaster :: GanetiDaemon -> Bool
- daemonLogBase :: GanetiDaemon -> String
- daemonUser :: GanetiDaemon -> String
- daemonGroup :: GanetiGroup -> String
- data ExtraLogReason
- daemonsExtraLogbase :: GanetiDaemon -> ExtraLogReason -> String
- daemonLogFile :: GanetiDaemon -> IO FilePath
- daemonsExtraLogFile :: GanetiDaemon -> ExtraLogReason -> IO FilePath
- daemonPidFile :: GanetiDaemon -> IO FilePath
- allGroups :: [GanetiGroup]
- getEnts :: FromString e => ResultT e IO RuntimeEnts
- verifyDaemonUser :: GanetiDaemon -> RuntimeEnts -> IO ()
- checkUidMatch :: String -> UserID -> UserID -> IO ()
Documentation
data GanetiDaemon Source
Constructors
| GanetiMasterd | |
| GanetiMetad | |
| GanetiNoded | |
| GanetiRapi | |
| GanetiConfd | |
| GanetiWConfd | |
| GanetiKvmd | |
| GanetiLuxid | |
| GanetiMaintd | |
| GanetiMond |
Instances
| Bounded GanetiDaemon | |
| Enum GanetiDaemon | |
| Eq GanetiDaemon | |
| Ord GanetiDaemon | |
| Show GanetiDaemon |
Constructors
| DaemonsGroup | |
| AdminGroup |
data GanetiGroup Source
Constructors
| DaemonGroup GanetiDaemon | |
| ExtraGroup MiscGroup |
Instances
| Eq GanetiGroup | |
| Ord GanetiGroup | |
| Show GanetiGroup |
data RuntimeEnts Source
Constructors
| RuntimeEnts | |
Fields
| |
daemonName :: GanetiDaemon -> StringSource
Returns the daemon name for a given daemon.
daemonOnlyOnMaster :: GanetiDaemon -> BoolSource
Returns whether the daemon only runs on the master node.
daemonLogBase :: GanetiDaemon -> StringSource
Returns the log file base for a daemon.
daemonUser :: GanetiDaemon -> StringSource
Returns the configured user name for a daemon.
daemonGroup :: GanetiGroup -> StringSource
Returns the configured group for a daemon.
data ExtraLogReason Source
daemonsExtraLogbase :: GanetiDaemon -> ExtraLogReason -> StringSource
Some daemons might require more than one logfile. Specifically, right now only the Haskell http library snap, used by the monitoring daemon, requires multiple log files.
daemonLogFile :: GanetiDaemon -> IO FilePathSource
Returns the log file for a daemon.
daemonsExtraLogFile :: GanetiDaemon -> ExtraLogReason -> IO FilePathSource
Returns the extra log files for a daemon.
daemonPidFile :: GanetiDaemon -> IO FilePathSource
Returns the pid file name for a daemon.
getEnts :: FromString e => ResultT e IO RuntimeEntsSource
Computes the group/user maps.
verifyDaemonUser :: GanetiDaemon -> RuntimeEnts -> IO ()Source
Checks whether a daemon runs as the right user.
checkUidMatch :: String -> UserID -> UserID -> IO ()Source