spec

package
v0.0.4 Latest Latest
Warning

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

Go to latest
Published: Jul 6, 2017 License: Apache-2.0 Imports: 2 Imported by: 7

Documentation

Overview

This document contains all Quartermaster defined resources for Kubernetes. Sections with @DRIVER highlight Kubernetes resources where drivers can add specific information

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GlusterStorageCluster

type GlusterStorageCluster struct {
	Cluster string `json:"cluster"`
}

GlusterStorageCluster defines the specific information about the cluster

type GlusterStorageNode

type GlusterStorageNode struct {
	Cluster string `json:"cluster"` // Cluster ID this node should belong to.
	Node    string `json:"node"`    // Node ID
	Zone    int    `json:"zone"`    // Zone ID this node belongs to. If missing, Zone 1 will be assumed.
}

GlusterStorageNode defines the specifics of how this Gluster instance should be instantiated.

type NFSStorageNode

type NFSStorageNode struct {
	ReadOnly bool   `json:"readOnly"` // This node exports NFS volumes ReadOnly.
	Size     string `json:"size"`     // Size in GB of share
}

NFSStorageNode defines the specifics of how this Gluster instance should be instantiated.

type StatusCondition

type StatusCondition struct {
	Time    meta.Time `json:"time,omitempty"`
	Message string    `json:"message,omitempty"`
	Reason  string    `json:"reason,omitempty"`
}

type StatusInfo

type StatusInfo struct {
	Ready bool `json:"ready"`

	// The following follow the same definition as PodStatus
	Message string `json:"message,omitempty"`
	Reason  string `json:"reason,omitempty"`
}

type StorageCluster

type StorageCluster struct {
	meta.TypeMeta   `json:",inline"`
	meta.ObjectMeta `json:"metadata,omitempty"`
	Spec            StorageClusterSpec `json:"spec,omitempty"`

	// Status represents the current status of the storage node
	// +optional
	Status StorageClusterStatus `json:"status,omitempty"`
}

Third Party Resource object which contains all the necessary information to deploy a storage cluster

type StorageClusterCondition

type StorageClusterCondition struct {
	StatusCondition
	Type StorageClusterConditionType `json:"type,omitempty"`
}

type StorageClusterConditionType

type StorageClusterConditionType string
const (
	ClusterConditionReady   StorageClusterConditionType = "Ready"
	ClusterConditionOffline StorageClusterConditionType = "Offline"
)

type StorageClusterList

type StorageClusterList struct {
	meta.TypeMeta `json:",inline"`
	meta.ListMeta `json:"metadata,omitempty"`

	Items []StorageCluster `json:"items"`
}

StorageClusterList is a list of StorageCluster objects in Kubernetes

type StorageClusterSpec

type StorageClusterSpec struct {
	// Software defined storage type
	Type StorageTypeIdentifier `json:"type,omitempty"`

	// Specific image to use on all nodes of the cluster.  If not avaiable,
	// it defaults to the image from QuarterMaster
	// +optional
	Image string `json:"image,omitempty"`

	// All nodes participating in this cluster
	StorageNodes []StorageNodeSpec `json:"storageNodes,omitempty"`

	GlusterFS *GlusterStorageCluster `json:"glusterfs,omitempty"`
}

Specification for a StorageCluster

type StorageClusterStatus

type StorageClusterStatus struct {
	StatusInfo
	Conditions   []StorageClusterCondition `json:"conditions,omitempty"`
	NodeStatuses []StorageNodeStatus       `json:"nodeStatuses,omitempty"`
}

type StorageNode

type StorageNode struct {
	meta.TypeMeta   `json:",inline"`
	meta.ObjectMeta `json:"metadata,omitempty"`
	Spec            StorageNodeSpec `json:"spec,omitempty"`

	// Status represents the current status of the storage node
	// +optional
	Status StorageNodeStatus `json:"status,omitempty"`
}

StorageNode defines a single instance of available storage on a node and the appropriate options to apply to it to make it available to the cluster.

type StorageNodeCondition

type StorageNodeCondition struct {
	StatusCondition
	Type StorageNodeConditionType `json:"type,omitempty"`
}

type StorageNodeConditionType

type StorageNodeConditionType string
const (
	NodeConditionReady   StorageNodeConditionType = "Ready"
	NodeConditionOffline StorageNodeConditionType = "Offline"
)

type StorageNodeList

type StorageNodeList struct {
	meta.TypeMeta `json:",inline"`
	meta.ListMeta `json:"metadata,omitempty"`

	Items []StorageNode `json:"items"`
}

StorageNodeList is a list of StorageNode objects in Kubernetes.

type StorageNodeNetwork

type StorageNodeNetwork struct {
	IPs []string `json:"ips"`
}

StorageNodeNetwork specifies which network interfaces the StorageNode should use for data transport, which may be separate from it's Kubernetes-accessible IP.

type StorageNodeSpec

type StorageNodeSpec struct {
	// Software defined storage type
	Type StorageTypeIdentifier `json:"type,omitempty"`

	// Specific image to use on the storage node requested.  If not avaiable,
	// it defaults to the StorageCluster image.
	// +optional
	Image string `json:"image,omitempty"`

	// Request the storage node be scheduled on a specific node
	// Must have set either Node or NodeSelector
	// +optional
	NodeName string `json:"nodeName,omitempty"`

	// Request the storage node be scheduled on a node that matches the labels
	// Must have either Node or NodeSelector
	// +optional
	NodeSelector map[string]string `json:"nodeSelector,omitempty"`

	// Storage network if any
	StorageNetwork *StorageNodeNetwork `json:"storageNetwork,omitempty"`

	// Raw block devices available on the StorageNode to be used for storage.
	// Devices or Directories must be set and their use are specific to
	// the implementation
	// Must have set either Devices or Directories
	// +optional
	Devices []string `json:"devices,omitempty"`

	// Directory-based storage available on the StorageNode to be used for storage.
	// Devices or Directories must be set and their use are specific to
	// the implementation
	// Must have set either Devices or Directories
	// +optional
	Directories []string `json:"directories,omitempty"`

	// References the StorageCluster when bound to a cluster.  This is
	// when StorageCluster submits the StorageNode.
	ClusterRef *api.ObjectReference `json:"clusterRef,omitempty"`

	// Storage system settings
	// @DRIVER
	GlusterFS *GlusterStorageNode `json:"glusterfs,omitempty"`
	NFS       *NFSStorageNode     `json:"nfs,omitempty"`
}

StorageNodeSpec holds specification parameters for a StorageNode.

type StorageNodeStatus

type StorageNodeStatus struct {
	StatusInfo
	Added      bool                   `json:"added,omitempty"`
	Conditions []StorageNodeCondition `json:"conditions,omitempty"`
	PodName    string                 `json:"podName,omitempty"`
	NodeName   string                 `json:"nodeName,omitempty"`
}

type StorageTypeIdentifier

type StorageTypeIdentifier string
const (
	StorageTypeIdentifierMock      StorageTypeIdentifier = "mock"
	StorageTypeIdentifierNFS       StorageTypeIdentifier = "nfs"
	StorageTypeIdentifierGlusterFS StorageTypeIdentifier = "glusterfs"
	StorageTypeIdentifierSwift     StorageTypeIdentifier = "swift"
)

Add here the storage type identifier for your driver This is the storage type identifier administrators will use to identify which storage system to deploy. @DRIVER

Jump to

Keyboard shortcuts

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