components

package
v1.0.0-rc1 Latest Latest
Warning

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

Go to latest
Published: Dec 15, 2021 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Overview

Copyright © 2021 Dell Inc. or its subsidiaries. All Rights Reserved.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

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"`
	// +nullable
	// +optional
	Resources *ResourceRequirements `json:"resources,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"`

	// +nullable
	// +optional
	GlobalRegistry string `json:"globalRegistry"`
	// +nullable
	// +optional
	RegistrySecret string `json:"registrySecret"`
	// +kubebuilder:validation:Enum=IfNotPresent;Always;Never
	// +kubebuilder:default:=IfNotPresent
	PullPolicy string `json:"pullPolicy"`

	NodeSelector             *NodeSelector `json:"nodeSelector,omitempty"`
	NodeIDAnnotation         bool          `json:"nodeIDAnnotation,omitempty"`
	SequentialLVGReservation bool          `json:"sequentialLVGReservation,omitempty"`

	// +kubebuilder:validation:Enum=rke;openshift;vanilla
	// +kubebuilder:default:=vanilla
	Platform string `json:"platform"`
}

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"`
	// +nullable
	// +optional
	Resources *ResourceRequirements `json:"resources,omitempty"`
}

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
	// +optional
	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"`
	// +nullable
	// +optional
	Resources *ResourceRequirements `json:"resources,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"`
	// +nullable
	// +optional
	Resources *ResourceRequirements `json:"resources,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 {
	Enable            bool   `json:"enable"`
	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"`
	// +nullable
	// +optional
	Resources *ResourceRequirements `json:"resources,omitempty"`
}

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

type ResourceRequirements

type ResourceRequirements struct {
	// +nullable
	// +optional
	Limits corev1.ResourceList `json:"limits,omitempty"`
	// +nullable
	// +optional
	Requests corev1.ResourceList `json:"requests,omitempty"`
}

ResourceRequirements contain information for mem/cpu requirements

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"`
	// +nullable
	// +optional
	Resources *ResourceRequirements `json:"resources,omitempty"`
}

Scheduler encapsulates information to deploy CSI scheduler

type Sidecar

type Sidecar struct {
	Image *Image `json:"image,omitempty"`
	// +nullable
	// +optional
	Resources *ResourceRequirements `json:"resources,omitempty"`
}

Sidecar represent CSI sidecar containers

Jump to

Keyboard shortcuts

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