components

package
v0.4.0-beta Latest Latest
Warning

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

Go to latest
Published: Sep 7, 2021 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Controller

type Controller struct {
	Image    *Image              `json:"image,omitempty"`
	Log      *Log                `json:"log,omitempty"`
	Sidecars map[string]*Sidecar `json:"sidecars,omitempty"`
}

Controller encapsulates logic for CSI controller component

type DeploymentSpec

type DeploymentSpec struct {
	Driver                   *Driver         `json:"driver,omitempty"`
	NodeController           *NodeController `json:"nodeController,omitempty"`
	Scheduler                *Scheduler      `json:"scheduler,omitempty"`
	GlobalRegistry           string          `json:"globalRegistry,omitempty"`
	RegistrySecret           string          `json:"registrySecret,omitempty"`
	PullPolicy               string          `json:"pullPolicy,omitempty"`
	NodeSelector             *NodeSelector   `json:"nodeSelector,omitempty"`
	NodeIDAnnotation         bool            `json:"nodeIDAnnotation,omitempty"`
	SequentialLVGReservation bool            `json:"sequentialLVGReservation,omitempty"`
	Platform                 string          `json:"platform,omitempty"`
}

DeploymentSpec represent all CSI components need to be deployed by operator

type DriveMgr

type DriveMgr struct {
	Image    *Image `json:"image,omitempty"`
	Endpoint string `json:"endpoint"`
}

DriveMgr represents drive manager node component

type Driver

type Driver struct {
	Controller  *Controller  `json:"controller,omitempty"`
	Node        *Node        `json:"node,omitempty"`
	Metrics     *Metrics     `json:"metrics,omitempty"`
	LogReceiver *LogReceiver `json:"logReceiver,omitempty"`
	// todo need to implement this
	MountRootHost bool `json:"mountRootHost"`
}

Driver represent CSI driver with all necessary CSI components

type Format

type Format string

Format is format in which log will appear

const (
	// JSONFormat indicates that log are shown in json format
	JSONFormat Format = "json"
	// TextFormat indicates that log are shown in usual format
	TextFormat Format = "text"
)

type Image

type Image struct {
	Name string `json:"name"`
	Tag  string `json:"tag"`
}

Image contain information for components docker images

type Level

type Level string

Level indicates which types if logging need to be show

const (
	// InfoLevel includes Info, Error, Fatal, Warn logs
	InfoLevel Level = "info"
	// debug includes InfoLevel and Debug
	DebugLevel Level = "debug"
	// debug includes InfoLevel, DebugLevel and Trace
	TraceLevel Level = "trace"
)

type Log

type Log struct {
	Format Format `json:"format"`
	Level  Level  `json:"level"`
}

Log is a configuration for logger in components

type LogReceiver

type LogReceiver struct {
	Name  string `json:"name"`
	Image *Image `json:"image,omitempty"`
}

LogReceiver encapsulates information needed to establish log receiver for components

type Metrics

type Metrics struct {
	Path string `json:"path"`
	Port uint64 `json:"port"`
}

Metrics encapsulates necessary information to expose metric for different components

type Node

type Node struct {
	DriveMgr *DriveMgr           `json:"driveMgr,omitempty"`
	Image    *Image              `json:"image,omitempty"`
	Log      *Log                `json:"log,omitempty"`
	Sidecars map[string]*Sidecar `json:"sidecars,omitempty"`
}

Node encapsulates information for CSI node components

type NodeController

type NodeController struct {
	Enable bool   `json:"enable"`
	Image  *Image `json:"image,omitempty"`
	Log    *Log   `json:"log,omitempty"`
}

NodeController represent operator for CSI bare-metal nodes

type NodeSelector

type NodeSelector struct {
	Key   string `json:"key,omitempty"`
	Value string `json:"value,omitempty"`
}

NodeSelector contains key-value pair to deploy node components on specific k8sNodes

type Patcher

type Patcher struct {
	Image             *Image `json:"image,omitempty"`
	Interval          int    `json:"interval,omitempty"`
	RestoreOnShutdown bool   `json:"restoreOnShutdown,omitempty"`
	ConfigMapName     string `json:"configMapName,omitempty"`
	ReadinessTimeout  int    `json:"readinessTimeout,omitempty"`
}

Patcher represents scheduler patcher container, which tries to patch Kubernetes scheduler

type Scheduler

type Scheduler struct {
	Enable             bool     `json:"enable"`
	Image              *Image   `json:"image,omitempty"`
	Log                *Log     `json:"log,omitempty"`
	Metrics            *Metrics `json:"metrics,omitempty"`
	Patcher            *Patcher `json:"patcher,omitempty"`
	ExtenderPort       string   `json:"extenderPort,omitempty"`
	StorageProvisioner string   `json:"storageProvisioner"`
}

Scheduler encapsulates information to deploy CSI scheduler

type Sidecar

type Sidecar struct {
	Image *Image `json:"image,omitempty"`
}

Sidecar represent CSI sidecar containers

Jump to

Keyboard shortcuts

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