ganeti-htoolsSource codeContentsIndex
Ganeti.Ssconf
Description
Implementation of the Ganeti Ssconf interface.
Synopsis
maxFileSize :: Int
sSFilePrefix :: FilePath
data SSKey
= SSClusterName
| SSClusterTags
| SSFileStorageDir
| SSSharedFileStorageDir
| SSMasterCandidates
| SSMasterCandidatesIps
| SSMasterIp
| SSMasterNetdev
| SSMasterNetmask
| SSMasterNode
| SSNodeList
| SSNodePrimaryIps
| SSNodeSecondaryIps
| SSOfflineNodes
| SSOnlineNodes
| SSPrimaryIpFamily
| SSInstanceList
| SSReleaseVersion
| SSHypervisorList
| SSMaintainNodeHealth
| SSUidPool
| SSNodegroups
sSKeyFromRaw :: forall m[aPxW]. Monad m[aPxW] => String -> m[aPxW] SSKey
sSKeyToRaw :: SSKey -> String
keyToFilename :: Maybe FilePath -> SSKey -> FilePath
catchIOErrors :: Maybe a -> IO a -> IO (Result a)
readSSConfFile :: Maybe FilePath -> Maybe String -> SSKey -> IO (Result String)
rstripSpace :: String -> String
parseIPFamily :: Int -> Result Family
getPrimaryIPFamily :: Maybe FilePath -> IO (Result Family)
Documentation
maxFileSize :: IntSource
Maximum ssconf file size we support.
sSFilePrefix :: FilePathSource
ssconf file prefix, re-exported from Constants.
data SSKey Source
Constructors
SSClusterName
SSClusterTags
SSFileStorageDir
SSSharedFileStorageDir
SSMasterCandidates
SSMasterCandidatesIps
SSMasterIp
SSMasterNetdev
SSMasterNetmask
SSMasterNode
SSNodeList
SSNodePrimaryIps
SSNodeSecondaryIps
SSOfflineNodes
SSOnlineNodes
SSPrimaryIpFamily
SSInstanceList
SSReleaseVersion
SSHypervisorList
SSMaintainNodeHealth
SSUidPool
SSNodegroups
sSKeyFromRaw :: forall m[aPxW]. Monad m[aPxW] => String -> m[aPxW] SSKeySource
sSKeyToRaw :: SSKey -> StringSource
keyToFilenameSource
:: Maybe FilePathOptional config path override
-> SSKeyssconf key
-> FilePath
Convert a ssconf key into a (full) file path.
catchIOErrorsSource
::
=> Maybe aAction to run
-> IO a
-> IO (Result a)
Runs an IO action while transforming any error into Bad values. It also accepts an optional value to use in case the error is just does not exist.
readSSConfFileSource
:: Maybe FilePathOptional config path override
-> Maybe StringOptional default value
-> SSKeyDesired ssconf key
-> IO (Result String)
Read an ssconf file.
rstripSpace :: String -> StringSource
Strip space characthers (including newline). As this is expensive, should only be run on small strings.
parseIPFamily :: Int -> Result FamilySource
Parses a string containing an IP family
getPrimaryIPFamily :: Maybe FilePath -> IO (Result Family)Source
Read the primary IP family.
Produced by Haddock version 2.6.0