manila

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Jul 21, 2023 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// ServiceName - API V1 service name, deprecated
	ServiceName = "manila"
	// ServiceType - API V1 service type, deprecated
	ServiceType = "share"
	// ServiceNameV2 - API V2 service name, supported
	ServiceNameV2 = "manilav2"
	// ServiceTypeV2 - API V2 service type, supported
	ServiceTypeV2 = "sharev2"
	// DatabaseName -
	DatabaseName = "manila"

	// ManilaPublicPort -
	ManilaPublicPort int32 = 8786
	// ManilaInternalPort -
	ManilaInternalPort int32 = 8786

	// KollaConfigDbSync -
	KollaConfigDbSync = "/var/lib/config-data/merged/db-sync-config.json"

	// ManilaExtraVolTypeUndefined can be used to label an extraMount which
	// is not associated with a specific backend
	ManilaExtraVolTypeUndefined storage.ExtraVolType = "Undefined"
	// ManilaExtraVolTypeCeph can be used to label an extraMount which
	// is associated to a Ceph backend
	ManilaExtraVolTypeCeph storage.ExtraVolType = "Ceph"
	// ManilaShare is the definition of the manila-share group
	ManilaShare storage.PropagationType = "ManilaShare"
	// ManilaScheduler is the definition of the manila-scheduler group
	ManilaScheduler storage.PropagationType = "ManilaScheduler"
	// ManilaAPI is the definition of the manila-api group
	ManilaAPI storage.PropagationType = "ManilaAPI"
	// Manila is the global ServiceType that refers to all the components deployed
	// by the manila operator
	Manila storage.PropagationType = "Manila"
)
View Source
const (
	// DBSyncCommand -
	// FIXME?: The old CN-OSP use of bootstrap.sh does not work here, but not using it might be
	// a problem as it has a few conditionals that should perhaps be considered (and they're not here)
	DBSyncCommand = "/usr/local/bin/kolla_set_configs && su -s /bin/sh -c \"manila-manage db sync\""
)
View Source
const (
	// InitContainerCommand -
	InitContainerCommand = "/usr/local/bin/container-scripts/init.sh"
)

Variables

View Source
var DbsyncPropagation = []storage.PropagationType{storage.DBSync}

DbsyncPropagation keeps track of the DBSync Service Propagation Type

View Source
var ManilaAPIPropagation = []storage.PropagationType{Manila, ManilaAPI}

ManilaAPIPropagation is the definition of the ManilaAPI propagation group It allows the ManilaAPI pod to mount volumes destined to Manila and ManilaAPI ServiceTypes

View Source
var ManilaSchedulerPropagation = []storage.PropagationType{Manila, ManilaScheduler}

ManilaSchedulerPropagation is the definition of the ManilaScheduler propagation group It allows the ManilaScheduler pod to mount volumes destined to Manila and ManilaScheduler ServiceTypes

View Source
var ManilaSharePropagation = []storage.PropagationType{Manila, ManilaShare}

ManilaSharePropagation is the definition of the ManilaShare propagation group It allows the ManilaShare pods to mount volumes destined to Manila and ManilaShare ServiceTypes

Functions

func DbSyncJob

func DbSyncJob(instance *manilav1.Manila, labels map[string]string, annotations map[string]string) *batchv1.Job

DbSyncJob func

func GetConfigSecretVolumes

func GetConfigSecretVolumes(secretNames []string) ([]corev1.Volume, []corev1.VolumeMount)

GetConfigSecretVolumes - Returns a list of volumes associated with a list of Secret names

func GetInitVolumeMounts

func GetInitVolumeMounts(extraVol []manilav1.ManilaExtraVolMounts, svc []storage.PropagationType) []corev1.VolumeMount

GetInitVolumeMounts - Nova Control Plane init task VolumeMounts

func GetOwningManilaName

func GetOwningManilaName(instance client.Object) string

GetOwningManilaName - Given a ManilaAPI, ManilaScheduler, ManilaBackup or ManilaVolume object, returning the parent Manila object that created it (if any)

func GetVolumeMounts

func GetVolumeMounts(extraVol []manilav1.ManilaExtraVolMounts, svc []storage.PropagationType) []corev1.VolumeMount

GetVolumeMounts - Nova Control Plane VolumeMounts

func GetVolumes

func GetVolumes(name string, extraVol []manilav1.ManilaExtraVolMounts, svc []storage.PropagationType) []corev1.Volume

GetVolumes -

func InitContainer

func InitContainer(init APIDetails) []corev1.Container

InitContainer - init container for Manila pods

Types

type APIDetails

type APIDetails struct {
	ContainerImage       string
	DatabaseHost         string
	DatabaseUser         string
	DatabaseName         string
	OSPSecret            string
	TransportURLSecret   string
	DBPasswordSelector   string
	UserPasswordSelector string
	VolumeMounts         []corev1.VolumeMount
	Privileged           bool
	Debug                bool
	LoggingConf          bool
}

APIDetails information

Jump to

Keyboard shortcuts

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