Documentation
¶
Index ¶
- Constants
- func AnyResourcesInUse(resources []client.ResourceWithVolumes) bool
- func ClusterPrivateVolumeAgent(deployedVol client.Volume, resource string) *reactor.ResourceAgent
- func DevicePath(vol client.Volume) string
- func NoResourcesInUse(resources []client.ResourceWithVolumes) bool
- func WaitUntilResourceCondition(ctx context.Context, cli *client.Client, name string, ...) error
- type IpCidr
- type ResourceState
- type ResourceStatus
- type ServiceState
- type UidGid
- type ValidationError
- type Volume
- type VolumeConfig
- type VolumeState
Constants ¶
View Source
const ( ClusterPrivateVolumeMountPath = "/srv/ha/internal" ClusterPrivateVolumeAgentName = "fs_cluster_private" )
Variables ¶
This section is empty.
Functions ¶
func AnyResourcesInUse ¶
func AnyResourcesInUse(resources []client.ResourceWithVolumes) bool
func ClusterPrivateVolumeAgent ¶
func ClusterPrivateVolumeAgent(deployedVol client.Volume, resource string) *reactor.ResourceAgent
func DevicePath ¶
func NoResourcesInUse ¶
func NoResourcesInUse(resources []client.ResourceWithVolumes) bool
Types ¶
type ResourceState ¶
type ResourceState int
const ( Unknown ResourceState = iota ResourceStateOK ResourceStateDegraded ResourceStateBad )
func (ResourceState) MarshalJSON ¶
func (l ResourceState) MarshalJSON() ([]byte, error)
func (ResourceState) String ¶
func (l ResourceState) String() string
func (*ResourceState) UnmarshalJSON ¶
func (l *ResourceState) UnmarshalJSON(text []byte) error
type ResourceStatus ¶
type ResourceStatus struct { State ResourceState `json:"state"` Service ServiceState `json:"service"` Primary string `json:"primary"` Nodes []string `json:"nodes"` Volumes []VolumeState `json:"volumes"` }
type ServiceState ¶
type ServiceState int
const ( ServiceStateStopped ServiceState = iota ServiceStateStarted )
func (ServiceState) MarshalJSON ¶
func (s ServiceState) MarshalJSON() ([]byte, error)
func (ServiceState) String ¶
func (s ServiceState) String() string
func (*ServiceState) UnmarshalJSON ¶
func (s *ServiceState) UnmarshalJSON(text []byte) error
type ValidationError ¶
type ValidationError string
func (ValidationError) Error ¶
func (v ValidationError) Error() string
type Volume ¶
type Volume struct { Volume VolumeConfig `json:"volume"` Status VolumeState `json:"status"` }
type VolumeConfig ¶
type VolumeConfig struct { Number int `json:"number"` SizeKiB uint64 `json:"size_kib"` FileSystem string `json:"file_system,omitempty"` FileSystemRootOwner UidGid `json:"file_system_root_owner,omitempty"` }
func ClusterPrivateVolume ¶
func ClusterPrivateVolume() VolumeConfig
type VolumeState ¶
type VolumeState struct { Number int `json:"number"` State ResourceState `json:"state"` }
Click to show internal directories.
Click to hide internal directories.