|
|
|
|
|
Description |
Implementation of the Ganeti config objects.
Some object fields are not implemented yet, and as such they are
commented out below.
|
|
Synopsis |
|
| | nICModeFromRaw :: forall m[a1166]. Monad m[a1166] => String -> m[a1166] NICMode | | nICModeToRaw :: NICMode -> String | | data PartialNICParams = PartialNICParams {} | | data FilledNICParams = FilledNICParams {} | | fillNICParams :: FilledNICParams -> PartialNICParams -> FilledNICParams | | loadPartialNICParams :: JSValue -> Result PartialNICParams | | savePartialNICParams :: PartialNICParams -> JSValue | | toDictPartialNICParams :: PartialNICParams -> [(String, JSValue)] | | loadFilledNICParams :: JSValue -> Result FilledNICParams | | saveFilledNICParams :: FilledNICParams -> JSValue | | toDictFilledNICParams :: FilledNICParams -> [(String, JSValue)] | | data PartialNIC = PartialNIC {} | | loadPartialNIC :: JSValue -> Result PartialNIC | | savePartialNIC :: PartialNIC -> JSValue | | toDictPartialNIC :: PartialNIC -> [(String, JSValue)] | | | | diskModeFromRaw :: forall m[a11sX]. Monad m[a11sX] => String -> m[a11sX] DiskMode | | diskModeToRaw :: DiskMode -> String | | | | diskTypeFromRaw :: forall m[a11zo]. Monad m[a11zo] => String -> m[a11zo] DiskType | | diskTypeToRaw :: DiskType -> String | | | | fileDriverFromRaw :: forall m[a11FA]. Monad m[a11FA] => String -> m[a11FA] FileDriver | | fileDriverToRaw :: FileDriver -> String | | data BlockDriver = BlockDrvManual | | blockDriverFromRaw :: forall m[a11KZ]. Monad m[a11KZ] => String -> m[a11KZ] BlockDriver | | blockDriverToRaw :: BlockDriver -> String | | devType :: String | | | | lidDiskType :: DiskLogicalId -> DiskType | | lidEncodeType :: DiskLogicalId -> [(String, JSValue)] | | encodeDLId :: DiskLogicalId -> JSValue | | encodeFullDLId :: DiskLogicalId -> (JSValue, [(String, JSValue)]) | | decodeDLId :: [(String, JSValue)] -> JSValue -> Result DiskLogicalId | | data Disk = Disk {} | | loadDisk :: JSValue -> Result Disk | | saveDisk :: Disk -> JSValue | | toDictDisk :: Disk -> [(String, JSValue)] | | | | diskTemplateFromRaw :: forall m[a12eb]. Monad m[a12eb] => String -> m[a12eb] DiskTemplate | | diskTemplateToRaw :: DiskTemplate -> String | | | | adminStateFromRaw :: forall m[a12kO]. Monad m[a12kO] => String -> m[a12kO] AdminState | | adminStateToRaw :: AdminState -> String | | data PartialBEParams = PartialBEParams {} | | data FilledBEParams = FilledBEParams {} | | fillBEParams :: FilledBEParams -> PartialBEParams -> FilledBEParams | | loadPartialBEParams :: JSValue -> Result PartialBEParams | | savePartialBEParams :: PartialBEParams -> JSValue | | toDictPartialBEParams :: PartialBEParams -> [(String, JSValue)] | | loadFilledBEParams :: JSValue -> Result FilledBEParams | | saveFilledBEParams :: FilledBEParams -> JSValue | | toDictFilledBEParams :: FilledBEParams -> [(String, JSValue)] | | data Instance = Instance {} | | loadInstance :: JSValue -> Result Instance | | saveInstance :: Instance -> JSValue | | toDictInstance :: Instance -> [(String, JSValue)] | | data PartialNDParams = PartialNDParams {} | | data FilledNDParams = FilledNDParams {} | | fillNDParams :: FilledNDParams -> PartialNDParams -> FilledNDParams | | loadPartialNDParams :: JSValue -> Result PartialNDParams | | savePartialNDParams :: PartialNDParams -> JSValue | | toDictPartialNDParams :: PartialNDParams -> [(String, JSValue)] | | loadFilledNDParams :: JSValue -> Result FilledNDParams | | saveFilledNDParams :: FilledNDParams -> JSValue | | toDictFilledNDParams :: FilledNDParams -> [(String, JSValue)] | | data Node = Node {} | | loadNode :: JSValue -> Result Node | | saveNode :: Node -> JSValue | | toDictNode :: Node -> [(String, JSValue)] | | | | allocPolicyFromRaw :: forall m[a13pZ]. Monad m[a13pZ] => String -> m[a13pZ] AllocPolicy | | allocPolicyToRaw :: AllocPolicy -> String | | data NodeGroup = NodeGroup {} | | loadNodeGroup :: JSValue -> Result NodeGroup | | saveNodeGroup :: NodeGroup -> JSValue | | toDictNodeGroup :: NodeGroup -> [(String, JSValue)] | | data Cluster = Cluster {} | | loadCluster :: JSValue -> Result Cluster | | saveCluster :: Cluster -> JSValue | | toDictCluster :: Cluster -> [(String, JSValue)] | | data ConfigData = ConfigData {} | | loadConfigData :: JSValue -> Result ConfigData | | saveConfigData :: ConfigData -> JSValue | | toDictConfigData :: ConfigData -> [(String, JSValue)] |
|
|
|
NIC definitions
|
|
|
|
|
nICModeFromRaw :: forall m[a1166]. Monad m[a1166] => String -> m[a1166] NICMode | Source |
|
|
|
|
|
Constructors | PartialNICParams | | nicpModeP :: Maybe NICMode | | nicpLinkP :: Maybe String | |
|
|
|
|
|
Constructors | FilledNICParams | | nicpMode :: NICMode | | nicpLink :: String | |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Disk definitions
|
|
|
|
|
diskModeFromRaw :: forall m[a11sX]. Monad m[a11sX] => String -> m[a11sX] DiskMode | Source |
|
|
|
|
|
Constructors | LD_LV | | LD_DRBD8 | | LD_FILE | | LD_BLOCKDEV | | LD_RADOS | |
|
|
|
diskTypeFromRaw :: forall m[a11zo]. Monad m[a11zo] => String -> m[a11zo] DiskType | Source |
|
|
|
|
|
The file driver type.
| Constructors | |
|
|
fileDriverFromRaw :: forall m[a11FA]. Monad m[a11FA] => String -> m[a11FA] FileDriver | Source |
|
|
|
|
|
The persistent block driver type. Currently only one type is allowed.
| Constructors | |
|
|
blockDriverFromRaw :: forall m[a11KZ]. Monad m[a11KZ] => String -> m[a11KZ] BlockDriver | Source |
|
|
|
|
|
Constant for the dev_type key entry in the disk config.
|
|
|
The disk configuration type. This includes the disk type itself,
for a more complete consistency. Note that since in the Python
code-base there's no authoritative place where we document the
logical id, this is probably a good reference point.
| Constructors | LIDPlain String String | Volume group, logical volume
| LIDDrbd8 String String Int Int Int String | NodeA, NodeB, Port, MinorA, MinorB, Secret
| LIDFile FileDriver String | Driver, path
| LIDBlockDev BlockDriver String | Driver, path (must be under /dev)
| LIDRados String String | Unused, path
|
|
|
|
|
Mapping from a logical id to a disk type.
|
|
|
Builds the extra disk_type field for a given logical id.
|
|
|
Custom encoder for DiskLogicalId (logical id only).
|
|
|
Custom encoder for DiskLogicalId, composing both the logical id
and the extra disk_type field.
|
|
|
Custom decoder for DiskLogicalId. This is manual for now, since
we don't have yet automation for separate-key style fields.
|
|
|
Disk data structure.
This is declared manually as it's a recursive structure, and our TH
code currently can't build it.
| Constructors | |
|
|
|
|
|
|
|
|
Instance definitions
|
|
|
Instance disk template type. **Copied from HTools/Types.hs**
| Constructors | DTDiskless | | DTFile | | DTSharedFile | | DTPlain | | DTBlock | | DTDrbd8 | |
|
|
|
diskTemplateFromRaw :: forall m[a12eb]. Monad m[a12eb] => String -> m[a12eb] DiskTemplate | Source |
|
|
|
|
|
Constructors | AdminOffline | | AdminDown | | AdminUp | |
|
|
|
adminStateFromRaw :: forall m[a12kO]. Monad m[a12kO] => String -> m[a12kO] AdminState | Source |
|
|
|
|
|
Constructors | PartialBEParams | | bepMinmemP :: Maybe Int | | bepMaxmemP :: Maybe Int | | bepVcpusP :: Maybe Int | | bepAutoBalanceP :: Maybe Bool | |
|
|
|
|
|
Constructors | FilledBEParams | | bepMinmem :: Int | | bepMaxmem :: Int | | bepVcpus :: Int | | bepAutoBalance :: Bool | |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Constructors | Instance | | instName :: String | | instPrimaryNode :: String | | instOs :: String | | instHypervisor :: String | | instBeparams :: PartialBEParams | | instAdminState :: AdminState | | instNics :: [PartialNIC] | | instDisks :: [Disk] | | instDiskTemplate :: DiskTemplate | | instNetworkPort :: Maybe Int | | instCtime :: Double | | instMtime :: Double | | instUuid :: String | | instSerial :: Int | |
|
|
|
|
|
|
|
|
|
|
Node definitions
|
|
|
Constructors | PartialNDParams | | ndpOobProgramP :: Maybe String | |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Constructors | Node | | nodeName :: String | | nodePrimaryIp :: String | | nodeSecondaryIp :: String | | nodeMasterCandidate :: Bool | | nodeOffline :: Bool | | nodeDrained :: Bool | | nodeGroup :: String | | nodeMasterCapable :: Bool | | nodeVmCapable :: Bool | | nodePowered :: Bool | | nodeCtime :: Double | | nodeMtime :: Double | | nodeUuid :: String | | nodeSerial :: Int | |
|
|
|
|
|
|
|
|
|
|
NodeGroup definitions
|
|
|
The Group allocation policy type.
Note that the order of constructors is important as the automatic
Ord instance will order them in the order they are defined, so when
changing this data type be careful about the interaction with the
desired sorting order.
FIXME: COPIED from Types.hs; we need to eliminate this duplication later
| Constructors | AllocPreferred | | AllocLastResort | | AllocUnallocable | |
|
|
|
allocPolicyFromRaw :: forall m[a13pZ]. Monad m[a13pZ] => String -> m[a13pZ] AllocPolicy | Source |
|
|
|
|
|
Constructors | NodeGroup | | groupName :: String | | groupMembers :: [String] | | groupAllocPolicy :: AllocPolicy | | groupCtime :: Double | | groupMtime :: Double | | groupUuid :: String | | groupSerial :: Int | |
|
|
|
|
|
|
|
|
|
|
Cluster definitions
|
|
|
Constructors | Cluster | | clusterRsahostkeypub :: String | | clusterHighestUsedPort :: Int | | clusterTcpudpPortPool :: [Int] | | clusterMacPrefix :: String | | clusterVolumeGroupName :: String | | clusterReservedLvs :: [String] | | clusterMasterNode :: String | | clusterMasterIp :: String | | clusterMasterNetdev :: String | | clusterClusterName :: String | | clusterFileStorageDir :: String | | clusterEnabledHypervisors :: [String] | | clusterBeparams :: Container FilledBEParams | | clusterNicparams :: Container FilledNICParams | | clusterCandidatePoolSize :: Int | | clusterModifyEtcHosts :: Bool | | clusterModifySshSetup :: Bool | | clusterMaintainNodeHealth :: Bool | | clusterUidPool :: [Int] | | clusterDefaultIallocator :: String | | clusterHiddenOs :: [String] | | clusterBlacklistedOs :: [String] | | clusterPrimaryIpFamily :: Int | | clusterPreallocWipeDisks :: Bool | | clusterSerial :: Int | |
|
|
|
|
|
|
|
|
|
|
ConfigData definitions
|
|
|
|
|
|
|
|
|
|
|
Produced by Haddock version 2.6.0 |