propertiesv1

package
v21.11.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 26, 2022 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// SingleHostsCIDRMaskAddition contains the bits added as network part for single Host CIDR
	// Note: AWS limits netmask from /8 to /28, hence the 12...
	SingleHostsCIDRMaskAddition = 12
)

Variables

View Source
var (
	// SingleHostsMaxCIDRSlotValue contains the max index usable in function lib/utils/net.NthIncludedSubnet() to build CIDR
	SingleHostsMaxCIDRSlotValue = uint(math.Pow(2, SingleHostsCIDRMaskAddition) - 1)
)

Functions

This section is empty.

Types

type BucketMounts

type BucketMounts struct {
	ByHostID   map[string]string `json:"by_host_id"`
	ByHostName map[string]string `json:"by_host_name"`
}

BucketMounts contains information about hosts that have mounted the bucket not FROZEN yet Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental/overriding fields

func NewBucketMounts

func NewBucketMounts() *BucketMounts

NewBucketMounts ...

func (*BucketMounts) Clone

func (bm *BucketMounts) Clone() (data.Clonable, error)

Clone ... (data.Clonable interface)

func (*BucketMounts) IsNull

func (bm *BucketMounts) IsNull() bool

IsNull ... (data.Clonable interface)

func (*BucketMounts) Replace

func (bm *BucketMounts) Replace(p data.Clonable) (data.Clonable, error)

Replace ... (data.Clonable interface)

type ClusterComposite

type ClusterComposite struct {
	// Array of tenants hosting a multi-tenant cluster (multi starting from 1)
	Tenants []string `json:"tenants,omitempty"`
}

ClusterComposite ...

func (ClusterComposite) Clone

func (c ClusterComposite) Clone() (data.Clonable, error)

Clone ... satisfies interface data.Clonable

func (*ClusterComposite) IsNull

func (c *ClusterComposite) IsNull() bool

IsNull ... satisfies interface data.Clonable

func (*ClusterComposite) Replace

func (c *ClusterComposite) Replace(p data.Clonable) (data.Clonable, error)

Replace ... satisfies interface data.Clonable

type ClusterControlplane

type ClusterControlplane struct {
	VirtualIP *abstract.VirtualIP `json:"virtual_ip,omitempty"` // contains the VirtualIP used to contact the control plane when HA is enabled
}

ClusterControlplane contains information used by cluster control plane (when there is one) not FROZEN yet Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental fields

func (ClusterControlplane) Clone

func (cp ClusterControlplane) Clone() (data.Clonable, error)

Clone ... satisfies interface data.Clonable

func (*ClusterControlplane) IsNull

func (cp *ClusterControlplane) IsNull() bool

IsNull ... satisfies interface data.Clonable

func (*ClusterControlplane) Replace

func (cp *ClusterControlplane) Replace(p data.Clonable) (data.Clonable, error)

Replace ... satisfies interface data.Clonable

type ClusterDefaults

type ClusterDefaults struct {
	// GatewaySizing keeps the default node definition
	GatewaySizing abstract.HostEffectiveSizing `json:"gateway_sizing,omitempty"`
	// MasterSizing keeps the default node definition
	MasterSizing abstract.HostEffectiveSizing `json:"master_sizing,omitempty"`
	// NodeSizing keeps the default node definition
	NodeSizing abstract.HostEffectiveSizing `json:"node_sizing,omitempty"`
	// Image keeps the default Linux image to use
	Image string `json:"image,omitempty"`
}

ClusterDefaults contains default information used by the cluster after initial creation !!! FROZEN !!! !!! DEPRECATED !!! superseded by propertiesv2.ClusterDefaults

func (ClusterDefaults) Clone

func (d ClusterDefaults) Clone() (data.Clonable, error)

Clone ... (data.Clonable interface)

func (*ClusterDefaults) IsNull

func (d *ClusterDefaults) IsNull() bool

IsNull ... satisfies interface data.Clonable

func (*ClusterDefaults) Replace

func (d *ClusterDefaults) Replace(p data.Clonable) (data.Clonable, error)

Replace ... (data.Clonable interface)

type ClusterFeatures

type ClusterFeatures struct {
	// Installed ...
	Installed map[string]*ClusterInstalledFeature `json:"installed"`
	// Disabled keeps track of features normally automatically added with cluster creation,
	// but explicitly disabled; if a disabled feature is added, must be removed from this property
	Disabled map[string]struct{} `json:"disabled"`
}

ClusterFeatures ... not FROZEN yet

func (ClusterFeatures) Clone

func (f ClusterFeatures) Clone() (data.Clonable, error)

Clone ... satisfies interface data.Clonable

func (*ClusterFeatures) IsNull

func (f *ClusterFeatures) IsNull() bool

IsNull ... satisfies interface data.Clonable

func (*ClusterFeatures) Replace

func (f *ClusterFeatures) Replace(p data.Clonable) (data.Clonable, error)

Replace ... satisfies interface data.Clonable

type ClusterInstalledFeature

type ClusterInstalledFeature struct {
	Name       string              `json:"name"`                  // contains the name of the feature
	FileName   string              `json:"filename"`              // contains name of file used
	RequiredBy map[string]struct{} `json:"required_by,omitempty"` // tells what feature(s) needs this one
	Requires   map[string]struct{} `json:"requires,omitempty"`    // tells what feature(s) is(are) required by this one
}

ClusterInstalledFeature ... not FROZEN yet Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental/overriding fields

func NewClusterInstalledFeature

func NewClusterInstalledFeature() *ClusterInstalledFeature

NewClusterInstalledFeature ...

func (ClusterInstalledFeature) Clone

func (cif ClusterInstalledFeature) Clone() (data.Clonable, error)

Clone ... satisfies interface data.Clonable

func (*ClusterInstalledFeature) IsNull

func (cif *ClusterInstalledFeature) IsNull() bool

IsNull ... satisfies interface data.Clonable

func (*ClusterInstalledFeature) Replace

Replace ... satisfies interface data.Clonable

type ClusterNetwork

type ClusterNetwork struct {
	NetworkID string `json:"network_id,omitempty"` // contains the ID of the network
	GatewayID string `json:"gateway_id,omitempty"` // DEPRECATED
	GatewayIP string `json:"gateway_ip,omitempty"` // DEPRECATED
	PublicIP  string `json:"public_ip,omitempty"`  // DEPRECATED
	CIDR      string `json:"cidr,omitempty"`       // the network CIDR
}

ClusterNetwork contains network information relative to cluster !!! FROZEN !!! !!! DEPRECATED !!! superseded by propertiesv2.ClusterNetwork

func (ClusterNetwork) Clone

func (n ClusterNetwork) Clone() (data.Clonable, error)

Clone ... satisfies interface data.Clonable

func (*ClusterNetwork) IsNull

func (n *ClusterNetwork) IsNull() bool

IsNull ... satisfies interface data.Clonable

func (*ClusterNetwork) Replace

func (n *ClusterNetwork) Replace(p data.Clonable) (data.Clonable, error)

Replace ... satisfies interface data.Clonable

type ClusterNode

type ClusterNode struct {
	ID        string `json:"id"`         // ID of the node
	Name      string `json:"name"`       // GetName of the node
	PublicIP  string `json:"public_ip"`  // public ip of the node
	PrivateIP string `json:"private_ip"` // private ip of the node
}

ClusterNode ...

type ClusterNodes

type ClusterNodes struct {
	Masters          []*ClusterNode `json:"masters,omitempty"`            // Masters contains the ID of the masters
	PublicNodes      []*ClusterNode `json:"public_nodes,omitempty"`       // PublicNodes is a slice of IDs of the public cluster nodes
	PrivateNodes     []*ClusterNode `json:"private_nodes,omitempty"`      // PrivateNodes is a slice of IDs of the private cluster nodes
	MasterLastIndex  int            `json:"master_last_index,omitempty"`  // MasterLastIndex
	PrivateLastIndex int            `json:"private_last_index,omitempty"` // PrivateLastIndex
	PublicLastIndex  int            `json:"public_last_index,omitempty"`  // PublicLastIndex
}

ClusterNodes ...

func (ClusterNodes) Clone

func (n ClusterNodes) Clone() (data.Clonable, error)

Clone ... (data.Clonable interface)

func (*ClusterNodes) IsNull

func (n *ClusterNodes) IsNull() bool

IsNull ... satisfies interface data.Clonable

func (*ClusterNodes) Replace

func (n *ClusterNodes) Replace(p data.Clonable) (data.Clonable, error)

Replace ... (data.Clonable interface)

type ClusterState

type ClusterState struct {
	State                clusterstate.Enum `json:"state,omitempty"`                  // State of the cluster
	StateCollectInterval time.Duration     `json:"state_collect_interval,omitempty"` // in seconds

}

ClusterState contains the bare minimum information about the state of a cluster

func (ClusterState) Clone

func (s ClusterState) Clone() (data.Clonable, error)

Clone ... satisfies interface data.Clonable

func (*ClusterState) IsNull

func (s *ClusterState) IsNull() bool

IsNull ... satisfies interface data.Clonable

func (*ClusterState) Replace

func (s *ClusterState) Replace(p data.Clonable) (data.Clonable, error)

Replace ... satisfies interface data.Clonable

type FreeCIDRSlot

type FreeCIDRSlot struct {
	First uint // contains the index of the first available CIDR (to use in lib/utils/net.NthIncludedSubnet() to find corresponding CIDR)
	Last  uint // contains the index of the last available CIDR
}

type HostClusterMembership

type HostClusterMembership struct {
	Cluster string `json:"cluster,omitempty"`   // Cluster is the name of the cluster the host is member of
	Type    string `json:"node_type,omitempty"` // Tells if host is "node", "master" or "gateway"
}

HostClusterMembership ... not FROZEN yet Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental fields

func NewHostClusterMembership

func NewHostClusterMembership() *HostClusterMembership

NewHostClusterMembership ...

func (HostClusterMembership) Clone

func (hcm HostClusterMembership) Clone() (data.Clonable, error)

Clone ...

func (*HostClusterMembership) IsNull

func (hcm *HostClusterMembership) IsNull() bool

IsNull ... satisfies interface data.Clonable

func (*HostClusterMembership) Replace

Replace ...

func (*HostClusterMembership) Reset

func (hcm *HostClusterMembership) Reset()

Reset resets the content of the property

type HostDescription

type HostDescription struct {
	Created time.Time `json:"created,omitempty"`  // tells when the host has been created
	Creator string    `json:"creator,omitempty"`  // contains information (forged) about the creator of the host
	Updated time.Time `json:"modified,omitempty"` // tells the last time the host has been modified (by SafeScale)
	Purpose string    `json:"purpose,omitempty"`  // contains a description of the use of a host (not set for now)
	Tenant  string    `json:"tenant,omitempty"`   // contains the tenant name used to create the host
	Domain  string    `json:"domain,omitempty"`   // Contains the domain used to define the FQDN of the host at creation (taken from first network attached to the host)
}

HostDescription contains description information for the host not FROZEN yet Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental fields

func NewHostDescription

func NewHostDescription() *HostDescription

NewHostDescription ...

func (HostDescription) Clone

func (hd HostDescription) Clone() (data.Clonable, error)

Clone ... (data.Clonable interface)

func (*HostDescription) IsNull

func (hd *HostDescription) IsNull() bool

IsNull ... satisfies interface data.Clonable

func (*HostDescription) Replace

func (hd *HostDescription) Replace(p data.Clonable) (data.Clonable, error)

Replace ... (data.Clonable interface)

type HostEffectiveSizing

type HostEffectiveSizing struct {
	Cores     int     `json:"cores,omitempty"`
	RAMSize   float32 `json:"ram_size,omitempty"`
	DiskSize  int     `json:"disk_size,omitempty"`
	GPUNumber int     `json:"gpu_number,omitempty"`
	GPUType   string  `json:"gpu_type,omitempty"`
	CPUFreq   float32 `json:"cpu_freq,omitempty"`
}

HostEffectiveSizing represent sizing elements of a host !!! FROZEN !!! Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental fields

func NewHostEffectiveSizing

func NewHostEffectiveSizing() *HostEffectiveSizing

NewHostEffectiveSizing ...

func (*HostEffectiveSizing) IsNull

func (hes *HostEffectiveSizing) IsNull() bool

IsNull ...

type HostFeatures

type HostFeatures struct {
	Installed map[string]*HostInstalledFeature `json:"installed,omitempty"` // list of installed features, indexed on feature name
}

HostFeatures ... not FROZEN yet Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental fields

func NewHostFeatures

func NewHostFeatures() *HostFeatures

NewHostFeatures ...

func (HostFeatures) Clone

func (hf HostFeatures) Clone() (data.Clonable, error)

Clone ... (data.Clonable interface)

func (*HostFeatures) IsNull

func (hf *HostFeatures) IsNull() bool

IsNull ... satisfies interface data.Clonable

func (*HostFeatures) Replace

func (hf *HostFeatures) Replace(p data.Clonable) (data.Clonable, error)

Replace ... (data.Clonable interface)

func (*HostFeatures) Reset

func (hf *HostFeatures) Reset()

Reset resets the content of the property

type HostInstalledFeature

type HostInstalledFeature struct {
	HostContext bool                `json:"host_context,omitempty"` // tells if the feature has been explicitly installed for host (opposed to for cluster)
	RequiredBy  map[string]struct{} `json:"required_by,omitempty"`  // tells what feature(s) needs this one
	Requires    map[string]struct{} `json:"requires,omitempty"`
}

HostInstalledFeature ... not FROZEN yet Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental/overriding fields

func NewHostInstalledFeature

func NewHostInstalledFeature() *HostInstalledFeature

NewHostInstalledFeature ...

func (*HostInstalledFeature) Clone

func (hif *HostInstalledFeature) Clone() (data.Clonable, error)

Clone ... satisfies interface data.Clonable

func (*HostInstalledFeature) IsNull

func (hif *HostInstalledFeature) IsNull() bool

IsNull ... satisfies interface data.Clonable

func (*HostInstalledFeature) Replace

func (hif *HostInstalledFeature) Replace(p data.Clonable) (data.Clonable, error)

Replace ... satisfies interface data.Clonable

type HostLocalMount

type HostLocalMount struct {
	Device     string `json:"device"`            // Device is the name of the device (/dev/... for local mount, host:/path for remote mount)
	Path       string `json:"mountpoint"`        // Path is the mount point of the device
	FileSystem string `json:"file_system"`       // FileSystem tells the filesystem used
	Options    string `json:"options,omitempty"` // Options contains the mount options
}

HostLocalMount stores information about a device (as an attached volume) mount !!! FROZEN !!! Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental/overriding fields

func NewHostLocalMount

func NewHostLocalMount() *HostLocalMount

NewHostLocalMount ...

func (HostLocalMount) Clone

func (hlm HostLocalMount) Clone() (data.Clonable, error)

Clone ... satisfies interface data.Clonable

func (*HostLocalMount) IsNull

func (hlm *HostLocalMount) IsNull() bool

IsNull ... satisfies interface data.Clonable

func (*HostLocalMount) Replace

func (hlm *HostLocalMount) Replace(p data.Clonable) (data.Clonable, error)

Replace ...

type HostMounts

type HostMounts struct {
	LocalMountsByDevice   map[string]string           `json:"local_mounts_by_device,omitempty"`  // contains local mount path, indexed by devices
	LocalMountsByPath     map[string]*HostLocalMount  `json:"local_mounts_by_path,omitempty"`    // contains HostLocalMount structs, indexed by path
	RemoteMountsByShareID map[string]string           `json:"remote_mounts_by_device,omitempty"` // contains local mount path, indexed by Share ID
	RemoteMountsByExport  map[string]string           `json:"remote_mounts_by_export,omitempty"` // contains local mount path, indexed by export
	RemoteMountsByPath    map[string]*HostRemoteMount `json:"remote_mounts_by_path,omitempty"`   // contains HostRemoteMount, indexed by path
	BucketMounts          map[string]string           `json:"bucket_mounts,omitempty"`           // contains the path where the index (corresponding to Bucket name) is mounted
}

HostMounts contains information about mounts on the host !!! FROZEN !!! Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental/overriding fields

func NewHostMounts

func NewHostMounts() *HostMounts

NewHostMounts ...

func (*HostMounts) Clone

func (hm *HostMounts) Clone() (data.Clonable, error)

Clone ... (data.Clonable interface)

func (*HostMounts) IsNull

func (hm *HostMounts) IsNull() bool

IsNull ... (data.Clonable interface)

func (*HostMounts) Replace

func (hm *HostMounts) Replace(p data.Clonable) (data.Clonable, error)

Replace ... (data.Clonable interface)

type HostNetwork

type HostNetwork struct {
	IsGateway               bool              `json:"is_gateway,omitempty"`                 // Tells if host is a gateway of a network
	DefaultGatewayID        string            `json:"default_gateway_id,omitempty"`         // DEPRECATED: contains the ID of the Default getGateway
	DefaultGatewayPrivateIP string            `json:"default_gateway_private_ip,omitempty"` // DEPRECATED: contains the private IP of the default gateway
	DefaultNetworkID        string            `json:"default_network_id,omitempty"`         // contains the ID of the default Networking
	NetworksByID            map[string]string `json:"networks_by_id,omitempty"`             // contains the name of each network bound to the host (indexed by ID)
	NetworksByName          map[string]string `json:"networks_by_name,omitempty"`           // contains the ID of each network bound to the host (indexed by GetName)
	PublicIPv4              string            `json:"public_ip_v4,omitempty"`               // contains the public IPv4 address of the host
	PublicIPv6              string            `json:"public_ip_v6,omitempty"`               // contains the public IPv6 address of the host
	IPv4Addresses           map[string]string `json:"ipv4_addresses,omitempty"`             // contains ipv4 (indexed by Networking ID) allocated to the host
	IPv6Addresses           map[string]string `json:"ipv6_addresses,omitempty"`             // contains ipv6 (indexed by Networking ID) allocated to the host
}

HostNetwork contains network information related to Host !!! FROZEN !!! Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental fields

func NewHostNetwork

func NewHostNetwork() *HostNetwork

NewHostNetwork ...

func (HostNetwork) Clone

func (hn HostNetwork) Clone() (data.Clonable, error)

Clone ... satisfies interface data.Clonable

func (*HostNetwork) IsNull

func (hn *HostNetwork) IsNull() bool

IsNull tells if the HostNetwork corresponds to a null value

func (*HostNetwork) Replace

func (hn *HostNetwork) Replace(p data.Clonable) (data.Clonable, error)

Replace ... satisfies interface data.Clonable

func (*HostNetwork) Reset

func (hn *HostNetwork) Reset()

Reset resets the content of the property

type HostRemoteMount

type HostRemoteMount struct {
	ShareID    string `json:"share_id"`          // contains the ID of the share mounted
	Export     string `json:"export"`            // contains the path of the export (ie: <host>:/data/shared)
	Path       string `json:"mountpoint"`        // Path is the mount point of the device
	FileSystem string `json:"file_system"`       // FileSystem tells the filesystem used
	Options    string `json:"options,omitempty"` // Options contains the mount options
}

HostRemoteMount stores information about a remote filesystem mount !!! FROZEN !!! Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental/overriding fields

func NewHostRemoteMount

func NewHostRemoteMount() *HostRemoteMount

NewHostRemoteMount ...

func (*HostRemoteMount) Clone

func (hrm *HostRemoteMount) Clone() (data.Clonable, error)

Clone ...

func (*HostRemoteMount) IsNull

func (hrm *HostRemoteMount) IsNull() bool

IsNull ...

func (*HostRemoteMount) Replace

func (hrm *HostRemoteMount) Replace(p data.Clonable) (data.Clonable, error)

Replace ...

type HostSecurityGroups

type HostSecurityGroups struct {
	// DefaultID string                        `json:"default_id,omitempty"` // contains the ID of the Security Group considered as default
	ByID   map[string]*SecurityGroupBond `json:"by_id,omitempty"`   // map of security groups by IDs
	ByName map[string]string             `json:"by_name,omitempty"` // map of security group IDs by Names
}

HostSecurityGroups contains a list of security groups bound to the host !!! FROZEN !!! Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental fields

func NewHostSecurityGroups

func NewHostSecurityGroups() *HostSecurityGroups

NewHostSecurityGroups ...

func (HostSecurityGroups) Clone

func (hsg HostSecurityGroups) Clone() (data.Clonable, error)

Clone ...

func (*HostSecurityGroups) IsNull

func (hsg *HostSecurityGroups) IsNull() bool

IsNull ...

func (*HostSecurityGroups) Replace

func (hsg *HostSecurityGroups) Replace(p data.Clonable) (data.Clonable, error)

Replace ...

type HostShare

type HostShare struct {
	ID            string            `json:"id"`                        // ID ...
	Name          string            `json:"name"`                      // the name of the share
	Path          string            `json:"path"`                      // the path on the host filesystem that is shared
	PathAcls      string            `json:"path_acls,omitempty"`       // filesystem acls to set on the exported folder
	Type          string            `json:"type,omitempty"`            // export type is lowercase (ie. nfs, glusterfs, ...)
	ShareAcls     string            `json:"share_acls,omitempty"`      // the acls to set on the share
	ShareOptions  string            `json:"share_options,omitempty"`   // the options (other than acls) to set on the share
	ClientsByID   map[string]string `json:"clients_by_id,omitempty"`   // contains the name of the hosts mounting the export, indexed by host ID
	ClientsByName map[string]string `json:"clients_by_name,omitempty"` // contains the ID of the hosts mounting the export, indexed by host GetName
}

HostShare describes a filesystem exported from the host !!! FROZEN !!! Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental/overriding fields

func NewHostShare

func NewHostShare() *HostShare

NewHostShare ...

func (HostShare) Clone

func (hs HostShare) Clone() (data.Clonable, error)

Clone ...

func (*HostShare) IsNull

func (hs *HostShare) IsNull() bool

IsNull ...

func (*HostShare) Replace

func (hs *HostShare) Replace(p data.Clonable) (data.Clonable, error)

Replace ...

type HostShares

type HostShares struct {
	ByID   map[string]*HostShare `json:"by_id,omitempty"`
	ByName map[string]string     `json:"by_name,omitempty"`
}

HostShares contains information about the shares of the host !!! FROZEN !!! Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental/overriding fields

func NewHostShares

func NewHostShares() *HostShares

NewHostShares ...

func (HostShares) Clone

func (hs HostShares) Clone() (data.Clonable, error)

Clone ...

func (*HostShares) IsNull

func (hs *HostShares) IsNull() bool

IsNull ...

func (*HostShares) Replace

func (hs *HostShares) Replace(p data.Clonable) (data.Clonable, error)

Replace ...

type HostSizing

type HostSizing struct {
	RequestedSize *HostSizingRequirements `json:"requested_size,omitempty"`
	Template      string                  `json:"template,omitempty"`
	AllocatedSize *HostEffectiveSizing    `json:"allocated_size,omitempty"`
}

HostSizing contains sizing information about the host !!! FROZEN !!! Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental fields

func NewHostSizing

func NewHostSizing() *HostSizing

NewHostSizing ...

func (HostSizing) Clone

func (hs HostSizing) Clone() (data.Clonable, error)

Clone ... (data.Clonable interface)

func (*HostSizing) IsNull

func (hs *HostSizing) IsNull() bool

IsNull ... (data.Clonable interface)

func (*HostSizing) Replace

func (hs *HostSizing) Replace(p data.Clonable) (data.Clonable, error)

Replace ...

type HostSizingRequirements

type HostSizingRequirements struct {
	Cores     int     `json:"cores,omitempty"`
	RAMSize   float32 `json:"ram_size,omitempty"`
	DiskSize  int     `json:"disk_size,omitempty"`
	GPUNumber int     `json:"gpu_number,omitempty"`
	GPUType   string  `json:"gpu_type,omitempty"`
	CPUFreq   float32 `json:"cpu_freq,omitempty"`
}

HostSizingRequirements describes host sizing requirements to fulfill !!! FROZEN !!! Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental fields

func NewHostSizingRequirements

func NewHostSizingRequirements() *HostSizingRequirements

NewHostSizingRequirements ...

func (*HostSizingRequirements) IsNull

func (hsr *HostSizingRequirements) IsNull() bool

IsNull ...

type HostSystem

type HostSystem struct {
	Type     string `json:"type,omitempty"`     // Type of operating system (ie linux, windows, ... Not normalized yet...)
	Flavor   string `json:"flavor,omitempty"`   // Flavor of operating system (ie 'ubuntu server', 'windows server 2016', ... Not normalized yet...)
	Image    string `json:"image,omitempty"`    // name of the provider's image used
	HostName string `json:"hostname,omitempty"` // Hostname on the system
}

HostSystem contains information about the operating system not FROZEN yet Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental fields

func NewHostSystem

func NewHostSystem() *HostSystem

NewHostSystem ...

func (HostSystem) Clone

func (hs HostSystem) Clone() (data.Clonable, error)

Clone ...

func (*HostSystem) IsNull

func (hs *HostSystem) IsNull() bool

IsNull ...

func (*HostSystem) Replace

func (hs *HostSystem) Replace(p data.Clonable) (data.Clonable, error)

Replace ...

type HostVolume

type HostVolume struct {
	AttachID string `json:"attach_id"` // contains the ID of the volume attachment
	Device   string `json:"device"`    // contains the device on the host
}

HostVolume contains information about attached volume not FROZEN yet Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental fields

func NewHostVolume

func NewHostVolume() *HostVolume

NewHostVolume ...

type HostVolumes

type HostVolumes struct {
	VolumesByID     map[string]*HostVolume `json:"volumes_by_id,omitempty"`     // contains the information of the attached volume, indexed by volume ID
	VolumesByName   map[string]string      `json:"volumes_by_name,omitempty"`   // contains the ID of attached volume, indexed by volume name
	VolumesByDevice map[string]string      `json:"volumes_by_device,omitempty"` // contains the ID of attached volume, indexed by device
	DevicesByID     map[string]string      `json:"devices_by_id,omitempty"`     // contains the device of attached volume, indexed by ID
}

HostVolumes contains information about attached volumes not FROZEN yet Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental fields

func NewHostVolumes

func NewHostVolumes() *HostVolumes

NewHostVolumes ...

func (HostVolumes) Clone

func (hv HostVolumes) Clone() (data.Clonable, error)

Clone ...

func (*HostVolumes) IsNull

func (hv *HostVolumes) IsNull() bool

IsNull ...

func (*HostVolumes) Replace

func (hv *HostVolumes) Replace(p data.Clonable) (data.Clonable, error)

Replace ...

type NetworkDescription

type NetworkDescription struct {
	Purpose string    `json:"purpose,omitempty"` // contains the purpose of this network
	Created time.Time `json:"created,omitempty"` // Contains the date of creation of the network
	Domain  string    `json:"domain,omitempty"`  // Deprecated (moved to SubnetDescription): defines the domain to use for host FQDN in this network
}

NetworkDescription contains additional information describing the network, in V1 not FROZEN yet Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental fields

func NewNetworkDescription

func NewNetworkDescription() *NetworkDescription

NewNetworkDescription ...

func (NetworkDescription) Clone

func (nd NetworkDescription) Clone() (data.Clonable, error)

Clone ... (data.Clonable interface)

func (*NetworkDescription) IsNull

func (nd *NetworkDescription) IsNull() bool

IsNull ... (data.Clonable interface)

func (*NetworkDescription) Replace

func (nd *NetworkDescription) Replace(p data.Clonable) (data.Clonable, error)

Replace ... (data.Clonable interface)

type NetworkHosts

type NetworkHosts struct {
	ByID   map[string]string `json:"by_id,omitempty"`   // list of host names, indexed by host id
	ByName map[string]string `json:"by_name,omitempty"` // list of host IDs, indexed by host name
}

NetworkHosts contains information about hosts connected to the network

func NewNetworkHosts

func NewNetworkHosts() *NetworkHosts

NewNetworkHosts ...

func (NetworkHosts) Clone

func (nh NetworkHosts) Clone() (data.Clonable, error)

Clone ... (data.Clonable interface)

func (*NetworkHosts) IsNull

func (nh *NetworkHosts) IsNull() bool

IsNull ... (data.Clonable interface)

func (*NetworkHosts) Replace

func (nh *NetworkHosts) Replace(p data.Clonable) (data.Clonable, error)

Replace ... (data.Clonable interface)

func (*NetworkHosts) Reset

func (nh *NetworkHosts) Reset()

Reset resets the content of the property

type NetworkSecurityGroups

type NetworkSecurityGroups struct {
	ByID   map[string]string `json:"by_id,omitempty"`   // map of security group names indexed by IDs
	ByName map[string]string `json:"by_name,omitempty"` // map of security group IDs indexed by names
}

NetworkSecurityGroups contains a list of security groups owned by the Network !!! FROZEN !!! Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental fields

func NewNetworkSecurityGroups

func NewNetworkSecurityGroups() *NetworkSecurityGroups

NewNetworkSecurityGroups ...

func (NetworkSecurityGroups) Clone

func (nsg NetworkSecurityGroups) Clone() (data.Clonable, error)

Clone ...

func (*NetworkSecurityGroups) IsNull

func (nsg *NetworkSecurityGroups) IsNull() bool

IsNull ...

func (*NetworkSecurityGroups) Replace

Replace ...

type NetworkSingleHosts

type NetworkSingleHosts struct {
	FreeSlots []FreeCIDRSlot `json:"free_slots,omitempty"` // contains a list of free CIDR in Network for single Hosts
}

NetworkSingleHosts contains additional information describing the CIDR used for single Hosts !!! FROZEN !!! Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental fields

func NewNetworkSingleHosts

func NewNetworkSingleHosts() *NetworkSingleHosts

NewNetworkSingleHosts ...

func (NetworkSingleHosts) Clone

func (nsh NetworkSingleHosts) Clone() (data.Clonable, error)

Clone ... (data.Clonable interface)

func (*NetworkSingleHosts) FreeSlot

func (nsh *NetworkSingleHosts) FreeSlot(index uint)

FreeSlot frees a slot

func (*NetworkSingleHosts) IsNull

func (nsh *NetworkSingleHosts) IsNull() bool

IsNull ... (data.Clonable interface)

func (*NetworkSingleHosts) Replace

func (nsh *NetworkSingleHosts) Replace(p data.Clonable) (data.Clonable, error)

Replace ... (data.Clonable interface)

func (*NetworkSingleHosts) ReserveSlot

func (nsh *NetworkSingleHosts) ReserveSlot() (index uint)

ReserveSlot returns the first free slot and remove it from list

type NetworkSubnets

type NetworkSubnets struct {
	ByID   map[string]string `json:"by_id,omitempty"`   // contains a list of subnet names indexed by id
	ByName map[string]string `json:"by_name,omitempty"` // contains a list of subnet ids index by name
}

NetworkSubnets contains additional information describing the subnets in a network, in V1 !!! FROZEN !!! Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental fields

func NewNetworkSubnets

func NewNetworkSubnets() *NetworkSubnets

NewNetworkSubnets ...

func (NetworkSubnets) Clone

func (nd NetworkSubnets) Clone() (data.Clonable, error)

Clone ... (data.Clonable interface)

func (*NetworkSubnets) IsNull

func (nd *NetworkSubnets) IsNull() bool

IsNull ... (data.Clonable interface)

func (*NetworkSubnets) Replace

func (nd *NetworkSubnets) Replace(p data.Clonable) (data.Clonable, error)

Replace ... (data.Clonable interface)

type SecurityGroupBond

type SecurityGroupBond struct {
	Name       string `json:"name"`
	ID         string `json:"id"`
	Disabled   bool   `json:"disabled"`
	FromSubnet bool   `json:"from_subnet"`
}

SecurityGroupBond stores information about a resource bound to the SecurityGroup

func NewSecurityGroupBond

func NewSecurityGroupBond() *SecurityGroupBond

NewSecurityGroupBond ...

func (SecurityGroupBond) Clone

func (sgb SecurityGroupBond) Clone() (data.Clonable, error)

Clone ...

func (*SecurityGroupBond) IsNull

func (sgb *SecurityGroupBond) IsNull() bool

IsNull ... Satisfies interface data.Clonable

func (*SecurityGroupBond) Replace

func (sgb *SecurityGroupBond) Replace(p data.Clonable) (data.Clonable, error)

Replace ...

type SecurityGroupHosts

type SecurityGroupHosts struct {
	DefaultFor string                        `json:"default_for,omitempty"` // contains the ID of the host for which the SecurityGroup is a default
	ByID       map[string]*SecurityGroupBond `json:"by_id,omitempty"`       // contains the status of a security group (true=active, false=suspended) of hosts using it, indexed on host ID
	ByName     map[string]string             `json:"by_name,omitempty"`     // contains the status of a security group (true=active, false=suspended) of hosts using it, indexed on host Name
}

SecurityGroupHosts contains information about attached hosts to a security group not FROZEN yet Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental fields

func NewSecurityGroupHosts

func NewSecurityGroupHosts() *SecurityGroupHosts

NewSecurityGroupHosts ...

func (*SecurityGroupHosts) Clone

func (sgh *SecurityGroupHosts) Clone() (data.Clonable, error)

Clone ...

func (*SecurityGroupHosts) IsNull

func (sgh *SecurityGroupHosts) IsNull() bool

IsNull ...

func (*SecurityGroupHosts) Replace

func (sgh *SecurityGroupHosts) Replace(p data.Clonable) (data.Clonable, error)

Replace ...

type SecurityGroupSubnets

type SecurityGroupSubnets struct {
	DefaultFor string                        `json:"default_for,omitempty"` // contains the ID of the subnet for which the Security Group is default
	ByID       map[string]*SecurityGroupBond `json:"by_id,omitempty"`       // contains the bonds of a Security Group with Subnets using it, indexed on Subnets' ID
	ByName     map[string]string             `json:"by_name,omitempty"`     // contains the Subnets' ID indexed on Subnets' Name
}

SecurityGroupSubnets contains information about attached subnets to a security group not FROZEN yet Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental fields

func NewSecurityGroupSubnets

func NewSecurityGroupSubnets() *SecurityGroupSubnets

NewSecurityGroupSubnets ...

func (SecurityGroupSubnets) Clone

func (sgn SecurityGroupSubnets) Clone() (data.Clonable, error)

Clone ...

func (*SecurityGroupSubnets) IsNull

func (sgn *SecurityGroupSubnets) IsNull() bool

IsNull ...

func (*SecurityGroupSubnets) Replace

func (sgn *SecurityGroupSubnets) Replace(p data.Clonable) (data.Clonable, error)

Replace ...

type SubnetDescription

type SubnetDescription struct {
	Purpose string    `json:"purpose,omitempty"` // contains the purpose of this network
	Created time.Time `json:"created,omitempty"` // Contains the date of creation if the network
	Domain  string    `json:"domain,omitempty"`  // Defines the domain to use for host FQDN in this network
}

SubnetDescription contains additional information describing the subnet, in V1 !!! FROZEN !!! Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental fields

func NewSubnetDescription

func NewSubnetDescription() *SubnetDescription

NewSubnetDescription ...

func (SubnetDescription) Clone

func (sd SubnetDescription) Clone() (data.Clonable, error)

Clone ... (data.Clonable interface)

func (*SubnetDescription) IsNull

func (sd *SubnetDescription) IsNull() bool

IsNull ... (data.Clonable interface)

func (*SubnetDescription) Replace

func (sd *SubnetDescription) Replace(p data.Clonable) (data.Clonable, error)

Replace ... (data.Clonable interface)

type SubnetHosts

type SubnetHosts struct {
	ByID   map[string]string `json:"by_id,omitempty"`   // list of host names, indexed by host id
	ByName map[string]string `json:"by_name,omitempty"` // list of host IDs, indexed by host name
}

SubnetHosts contains information about hosts attached to the subnet

func NewSubnetHosts

func NewSubnetHosts() *SubnetHosts

NewSubnetHosts ...

func (SubnetHosts) Clone

func (sh SubnetHosts) Clone() (data.Clonable, error)

Clone ... (data.Clonable interface)

func (*SubnetHosts) IsNull

func (sh *SubnetHosts) IsNull() bool

IsNull ... (data.Clonable interface)

func (*SubnetHosts) Replace

func (sh *SubnetHosts) Replace(p data.Clonable) (data.Clonable, error)

Replace ... (data.Clonable interface)

type SubnetSecurityGroups

type SubnetSecurityGroups struct {
	DefaultID string                        `json:"default_id,omitempty"` // Contains the ID of the default security group
	ByID      map[string]*SecurityGroupBond `json:"by_id,omitempty"`      // map of security groups by IDs; if value is true, security group is currently applied
	ByName    map[string]string             `json:"by_name,omitempty"`    // map of security group IDs by Names
}

SubnetSecurityGroups contains a list of security groups bound to the network, applied to each host created in it not FROZEN yet Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental fields

func NewSubnetSecurityGroups

func NewSubnetSecurityGroups() *SubnetSecurityGroups

NewSubnetSecurityGroups ...

func (SubnetSecurityGroups) Clone

func (ssg SubnetSecurityGroups) Clone() (data.Clonable, error)

Clone ...

func (*SubnetSecurityGroups) IsNull

func (ssg *SubnetSecurityGroups) IsNull() bool

IsNull ...

func (*SubnetSecurityGroups) Replace

func (ssg *SubnetSecurityGroups) Replace(p data.Clonable) (data.Clonable, error)

Replace ...

type VolumeAttachments

type VolumeAttachments struct {
	Shareable bool              `json:"shareable,omitempty"` // Tells if the volume can be shared with multiple host
	Hosts     map[string]string `json:"hosts,omitempty"`     // Contains the name of the hosts mounting the volume, indexed by host ID
}

VolumeAttachments contains host ids where the volume is attached !!!FROZEN!!! Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental fields

func NewVolumeAttachments

func NewVolumeAttachments() *VolumeAttachments

NewVolumeAttachments ...

func (VolumeAttachments) Clone

func (va VolumeAttachments) Clone() (data.Clonable, error)

Clone ... (data.Clonable interface)

func (*VolumeAttachments) IsNull

func (va *VolumeAttachments) IsNull() bool

IsNull ... (data.Clonable interface)

func (*VolumeAttachments) Replace

func (va *VolumeAttachments) Replace(p data.Clonable) (data.Clonable, error)

Replace ... (data.Clonable interface)

type VolumeDescription

type VolumeDescription struct {
	// Purpose contains the reason of the existence of the volume
	Purpose string `json:"purpose,omitempty"`
	// Created contains the time of creation of the volume
	Created time.Time `json:"created,omitempty"`
}

VolumeDescription contains additional information describing the volume, in V1 !!!FROZEN!!! Note: if tagged as FROZEN, must not be changed ever.

Create a new version instead with needed supplemental fields

func NewVolumeDescription

func NewVolumeDescription() *VolumeDescription

NewVolumeDescription ...

func (VolumeDescription) Clone

func (vd VolumeDescription) Clone() (data.Clonable, error)

Clone ...

func (*VolumeDescription) IsNull

func (vd *VolumeDescription) IsNull() bool

IsNull ...

func (*VolumeDescription) Replace

func (vd *VolumeDescription) Replace(p data.Clonable) (data.Clonable, error)

Replace ...

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL