v1alpha1

package
v0.32.0 Latest Latest
Warning

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

Go to latest
Published: Feb 28, 2023 License: Apache-2.0 Imports: 29 Imported by: 6

Documentation

Overview

+k8s:deepcopy-gen=package,register +k8s:openapi-gen=true +k8s:defaulter-gen=TypeMeta +kubebuilder:object:generate=true +groupName=schema.kubedb.com

Index

Constants

View Source
const (
	DatabaseNameAdmin  = "admin"
	DatabaseNameConfig = "config"
	DatabaseNameLocal  = "local"
	DatabaseForEntry   = "kubedb_system"
	SYSDatabase        = "sys"
)
View Source
const (
	DatabaseSchemaConditionTypeDBServerReady  DatabaseSchemaConditionType = "DatabaseServerReady"
	DatabaseSchemaMessageDBServerNotCreated   DatabaseSchemaMessage       = "Database Server is not created yet"
	DatabaseSchemaMessageDBServerProvisioning DatabaseSchemaMessage       = "Database Server is provisioning"
	DatabaseSchemaMessageDBServerReady        DatabaseSchemaMessage       = "Database Server is Ready"

	DatabaseSchemaConditionTypeVaultReady  DatabaseSchemaConditionType = "VaultReady"
	DatabaseSchemaMessageVaultNotCreated   DatabaseSchemaMessage       = "VaultServer is not created yet"
	DatabaseSchemaMessageVaultProvisioning DatabaseSchemaMessage       = "VaultServer is provisioning"
	DatabaseSchemaMessageVaultReady        DatabaseSchemaMessage       = "VaultServer is Ready"

	DatabaseSchemaConditionTypeDoubleOptInNotPossible DatabaseSchemaConditionType = "DoubleOptInNotPossible"
	DatabaseSchemaMessageDoubleOptInNotPossible       DatabaseSchemaMessage       = "Double OptIn is not possible between the applied Schema & Database server"

	DatabaseSchemaConditionTypeSecretEngineReady DatabaseSchemaConditionType = "SecretEngineReady"
	DatabaseSchemaMessageSecretEngineNotCreated  DatabaseSchemaMessage       = "SecretEngine is not created yet"
	DatabaseSchemaMessageSecretEngineCreating    DatabaseSchemaMessage       = "SecretEngine is being creating"
	DatabaseSchemaMessageSecretEngineSuccess     DatabaseSchemaMessage       = "SecretEngine phase is success"

	DatabaseSchemaConditionTypeRoleReady        DatabaseSchemaConditionType = "RoleReady"
	DatabaseSchemaMessageDatabaseRoleNotCreated DatabaseSchemaMessage       = "Database Role is not created yet"
	DatabaseSchemaMessageDatabaseRoleCreating   DatabaseSchemaMessage       = "Database Role is being creating"
	DatabaseSchemaMessageDatabaseRoleSuccess    DatabaseSchemaMessage       = "Database Role is success"

	DatabaseSchemaConditionTypeSecretAccessRequestReady DatabaseSchemaConditionType = "SecretAccessRequestReady"
	DatabaseSchemaMessageSecretAccessRequestNotCreated  DatabaseSchemaMessage       = "SecretAccessRequest is not created yet"
	DatabaseSchemaMessageSecretAccessRequestWaiting     DatabaseSchemaMessage       = "SecretAccessRequest is waiting for approval"
	DatabaseSchemaMessageSecretAccessRequestApproved    DatabaseSchemaMessage       = "SecretAccessRequest has been approved"
	DatabaseSchemaMessageSecretAccessRequestExpired     DatabaseSchemaMessage       = "SecretAccessRequest has been expired"

	DatabaseSchemaConditionTypeDBCreationUnsuccessful DatabaseSchemaConditionType = "DatabaseCreationUnsuccessful"
	DatabaseSchemaMessageSchemaNameConflicted         DatabaseSchemaMessage       = "Schema name is conflicted"
	DatabaseSchemaMessageDBCreationUnsuccessful       DatabaseSchemaMessage       = "Internal error occurred when creating database"

	DatabaseSchemaConditionTypeInitScriptCompleted DatabaseSchemaConditionType = "InitScriptCompleted"
	DatabaseSchemaMessageInitScriptNotApplied      DatabaseSchemaMessage       = "InitScript is not applied yet"
	DatabaseSchemaMessageInitScriptRunning         DatabaseSchemaMessage       = "InitScript is running"
	DatabaseSchemaMessageInitScriptCompleted       DatabaseSchemaMessage       = "InitScript is completed"
	DatabaseSchemaMessageInitScriptSucceeded       DatabaseSchemaMessage       = "InitScript is succeeded"
	DatabaseSchemaMessageInitScriptFailed          DatabaseSchemaMessage       = "InitScript is failed"

	DatabaseSchemaConditionTypeRepositoryFound DatabaseSchemaConditionType = "RepositoryFound"
	DatabaseSchemaMessageRepositoryNotCreated  DatabaseSchemaMessage       = "Repository is not created yet"
	DatabaseSchemaMessageRepositoryFound       DatabaseSchemaMessage       = "Repository has been found"

	DatabaseSchemaConditionTypeAppBindingFound DatabaseSchemaConditionType = "AppBindingFound"
	DatabaseSchemaMessageAppBindingNotCreated  DatabaseSchemaMessage       = "AppBinding is not created yet"
	DatabaseSchemaMessageAppBindingFound       DatabaseSchemaMessage       = "AppBinding is Found"

	DatabaseSchemaConditionTypeRestoreCompleted   DatabaseSchemaConditionType = "RestoreSessionCompleted"
	DatabaseSchemaMessageRestoreSessionNotCreated DatabaseSchemaMessage       = "RestoreSession is not created yet"
	DatabaseSchemaMessageRestoreSessionRunning    DatabaseSchemaMessage       = "RestoreSession is running"
	DatabaseSchemaMessageRestoreSessionSucceed    DatabaseSchemaMessage       = "RestoreSession is succeeded"
	DatabaseSchemaMessageRestoreSessionFailed     DatabaseSchemaMessage       = "RestoreSession is failed"
)
View Source
const (
	MySQLEncryptionEnabled  string = "'Y'"
	MySQLEncryptionDisabled string = "'N'"
)
View Source
const (
	ResourceKindMariaDBDatabase = "MariaDBDatabase"
	ResourceMariaDBDatabase     = "mariadbdatabase"
	ResourceMariaDBDatabases    = "mariadbdatabases"
)
View Source
const (
	InitScriptName              string = "init.js"
	MongoInitScriptPath         string = "init-scripts"
	MongoPrefix                 string = "MongoDB"
	MongoSuffix                 string = "mongo"
	MongoDatabaseNameForEntry   string = "kubedb-system"
	MongoCollectionNameForEntry string = "databases"
)
View Source
const (
	ResourceKindMongoDBDatabase = "MongoDBDatabase"
	ResourceMongoDBDatabase     = "mongodbdatabase"
	ResourceMongoDBDatabases    = "mongodbdatabases"
)
View Source
const (
	MongoDBValidateDeletionPolicyError     = "schema can't be deleted if the deletion policy is DoNotDelete"
	MongoDBValidateInitTypeBothError       = "cannot initialize database using both restore and initSpec"
	MongoDBValidateInitializedUnsetError   = "cannot unset the initialized field directly"
	MongoDBValidateDatabaseNameChangeError = "you can't change the Database Config name now"
	MongoDBValidateDBServerRefChangeError  = "cannot change mongodb reference"
	MongoDBValidateVaultRefChangeError     = "cannot change vault reference"
)
View Source
const (
	ResourceKindMySQLDatabase = "MySQLDatabase"
	ResourceMySQLDatabase     = "mysqldatabase"
	ResourceMySQLDatabases    = "mysqldatabases"
)
View Source
const (
	EnvPGPassword            string = "PGPASSWORD"
	EnvPGUser                string = "PGUSER"
	PostgresSchemaKubeSystem string = "kube_system"
)
View Source
const (
	ResourceKindPostgresDatabase = "PostgresDatabase"
	ResourcePostgresDatabase     = "postgresdatabase"
	ResourcePostgresDatabases    = "postgresdatabases"
)
View Source
const (
	MariaDBSuffix string = dbapi.ResourceSingularMariaDB
)
View Source
const (
	MySQLSuffix string = "mysql"
)

Variables

View Source
var (
	// SchemeGroupVersion is group version used to register these objects
	SchemeGroupVersion = schema.GroupVersion{Group: "schema.kubedb.com", Version: "v1alpha1"}

	// SchemeBuilder is used to add go types to the GroupVersionKind scheme
	SchemeBuilder = &scheme.Builder{GroupVersion: SchemeGroupVersion}

	// AddToScheme adds the types in this group-version to the given scheme.
	AddToScheme = SchemeBuilder.AddToScheme
)

Functions

func CheckIfDoubleOptInPossible

func CheckIfDoubleOptInPossible(schemaMeta metav1.ObjectMeta, schemaNSMeta metav1.ObjectMeta, dbNSMeta metav1.ObjectMeta, consumers *dbapi.AllowedConsumers) (bool, error)

CheckIfDoubleOptInPossible is the intended function to be called from operator It checks if the namespace, where SchemaDatabase is applied, is allowed. It also checks the labels of schemaDatabase, to decide if that is allowed or not.

func CheckIfInitScriptFailed

func CheckIfInitScriptFailed(conditions []kmapi.Condition) bool

func CheckIfRestoreFailed

func CheckIfRestoreFailed(conditions []kmapi.Condition) bool

func CheckIfSecretExpired

func CheckIfSecretExpired(conditions []kmapi.Condition) bool

func GetFinalizerForSchema

func GetFinalizerForSchema() string

func GetPostgresHostName

func GetPostgresHostName(db *kdm.Postgres) string

func GetPostgresInitJobContainerName

func GetPostgresInitJobContainerName(pgSchema *PostgresDatabase) string

func GetPostgresInitVolumeNameForPod

func GetPostgresInitVolumeNameForPod(pgSchema *PostgresDatabase) string

func GetPostgresSchemaAppBinding

func GetPostgresSchemaAppBinding(pgSchema *PostgresDatabase) string

func GetPostgresSchemaCreationStatements

func GetPostgresSchemaCreationStatements(pgSchema *PostgresDatabase) []string

func GetPostgresSchemaFinalizerString

func GetPostgresSchemaFinalizerString() string

func GetPostgresSchemaJobName

func GetPostgresSchemaJobName(pgSchema *PostgresDatabase) string

func GetPostgresSchemaRestoreSessionName

func GetPostgresSchemaRestoreSessionName(pgSchema *PostgresDatabase) string

func GetPostgresSchemaRevocationStatements

func GetPostgresSchemaRevocationStatements(pgSchema *PostgresDatabase) []string

func GetPostgresSchemaRoleName

func GetPostgresSchemaRoleName(pgSchema *PostgresDatabase) string

func GetPostgresSchemaRoleSecretAccessName

func GetPostgresSchemaRoleSecretAccessName(pgSchema *PostgresDatabase) string

func GetPostgresSchemaSecretEngineName

func GetPostgresSchemaSecretEngineName(pgSchema *PostgresDatabase) string

func GetPostgresSchemaSecretName

func GetPostgresSchemaSecretName(pgSchema *PostgresDatabase) string

func GetSchemaDoubleOptInLabelKey

func GetSchemaDoubleOptInLabelKey() string

func GetSchemaDoubleOptInLabelValue

func GetSchemaDoubleOptInLabelValue() string

func IsInAllowedNamespaces

func IsInAllowedNamespaces(schemaNSMeta metav1.ObjectMeta, dbNSMeta metav1.ObjectMeta, consumers *dbapi.AllowedConsumers) (bool, error)

func IsMatchByLabels

func IsMatchByLabels(schemaMeta metav1.ObjectMeta, consumers *dbapi.AllowedConsumers) (bool, error)

func Kind

func Kind(kind string) schema.GroupKind

Kind takes an unqualified kind and returns a Group qualified GroupKind

func Resource

func Resource(resource string) schema.GroupResource

Resource takes an unqualified resource and returns a Group qualified GroupResource

func ValidateMariaDBDatabaseUpdate added in v0.27.0

func ValidateMariaDBDatabaseUpdate(newobj *MariaDBDatabase, oldobj *MariaDBDatabase) error

func ValidateMySQLDatabaseUpdate

func ValidateMySQLDatabaseUpdate(newobj *MySQLDatabase, oldobj *MySQLDatabase) error

Types

type DatabaseSchemaConditionType

type DatabaseSchemaConditionType string

type DatabaseSchemaMessage

type DatabaseSchemaMessage string

type DatabaseSchemaPhase

type DatabaseSchemaPhase string

+kubebuilder:validation:Enum=Pending;InProgress;Terminating;Current;Failed;Expired

const (
	DatabaseSchemaPhasePending     DatabaseSchemaPhase = "Pending"
	DatabaseSchemaPhaseInProgress  DatabaseSchemaPhase = "InProgress"
	DatabaseSchemaPhaseTerminating DatabaseSchemaPhase = "Terminating"
	DatabaseSchemaPhaseCurrent     DatabaseSchemaPhase = "Current"
	DatabaseSchemaPhaseFailed      DatabaseSchemaPhase = "Failed"
	DatabaseSchemaPhaseExpired     DatabaseSchemaPhase = "Expired"
)

func GetPhase

func GetPhase(obj Interface) DatabaseSchemaPhase

type DatabaseStatus

type DatabaseStatus struct {
	// Specifies the current phase of the database
	// +optional
	Phase DatabaseSchemaPhase `json:"phase,omitempty"`
	// observedGeneration is the most recent generation observed for this resource. It corresponds to the
	// resource's generation, which is updated on mutation by the API Server.
	// +optional
	ObservedGeneration int64 `json:"observedGeneration,omitempty"`
	// Conditions applied to the database, such as approval or denial.
	// +optional
	Conditions []kmapi.Condition `json:"conditions,omitempty"`
	// Database authentication secret
	// +optional
	AuthSecret *core.LocalObjectReference `json:"authSecret,omitempty"`
}

DatabaseStatus defines the observed state of schema api types

func (*DatabaseStatus) DeepCopy

func (in *DatabaseStatus) DeepCopy() *DatabaseStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DatabaseStatus.

func (*DatabaseStatus) DeepCopyInto

func (in *DatabaseStatus) DeepCopyInto(out *DatabaseStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type DeletionPolicy

type DeletionPolicy string

+kubebuilder:validation:Enum=Delete;DoNotDelete

const (
	// DeletionPolicyDelete allows the created objects to be deleted
	DeletionPolicyDelete DeletionPolicy = "Delete"
	// DeletionPolicyDoNotDelete Rejects attempt to delete using ValidationWebhook.
	DeletionPolicyDoNotDelete DeletionPolicy = "DoNotDelete"
)

type InitSpec

type InitSpec struct {
	// Initialized indicates that this database has been initialized.
	// This will be set by the operator to ensure
	// that database is not mistakenly reset when recovered using disaster recovery tools.
	Initialized bool              `json:"initialized"`
	Script      *ScriptSourceSpec `json:"script,omitempty"`

	// Snapshot contains the restore-related details
	Snapshot *SnapshotSourceSpec `json:"snapshot,omitempty"`
}

func (*InitSpec) DeepCopy

func (in *InitSpec) DeepCopy() *InitSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new InitSpec.

func (*InitSpec) DeepCopyInto

func (in *InitSpec) DeepCopyInto(out *InitSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Interface

type Interface interface {
	metav1.Object
	GetInit() *InitSpec
	GetStatus() DatabaseStatus
}

type MariaDBDatabase

type MariaDBDatabase struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   MariaDBDatabaseSpec `json:"spec,omitempty"`
	Status DatabaseStatus      `json:"status,omitempty"`
}

+genclient +k8s:openapi-gen=true +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +kubebuilder:object:root=true +kubebuilder:resource:path=mariadbdatabases,singular=mariadbdatabase,shortName=mdschema,categories={datastore,kubedb,appscode,all} +kubebuilder:subresource:status +kubebuilder:printcolumn:name="DB_SERVER",type="string",JSONPath=".spec.database.serverRef.name" +kubebuilder:printcolumn:name="DB_NAME",type="string",JSONPath=".spec.database.config.name" +kubebuilder:printcolumn:name="Status",type="string",JSONPath=".status.phase" +kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp"

func (*MariaDBDatabase) CheckDoubleOptIn added in v0.27.0

func (in *MariaDBDatabase) CheckDoubleOptIn(ctx context.Context, client client.Client) (bool, error)

func (MariaDBDatabase) CustomResourceDefinition

func (_ MariaDBDatabase) CustomResourceDefinition() *apiextensions.CustomResourceDefinition

func (*MariaDBDatabase) DeepCopy

func (in *MariaDBDatabase) DeepCopy() *MariaDBDatabase

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MariaDBDatabase.

func (*MariaDBDatabase) DeepCopyInto

func (in *MariaDBDatabase) DeepCopyInto(out *MariaDBDatabase)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*MariaDBDatabase) DeepCopyObject

func (in *MariaDBDatabase) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*MariaDBDatabase) Default added in v0.27.0

func (r *MariaDBDatabase) Default()

Default implements webhook.Defaulter so a webhook will be registered for the type

func (*MariaDBDatabase) GetAppBindingMeta added in v0.27.0

func (in *MariaDBDatabase) GetAppBindingMeta() metav1.ObjectMeta

GetAppBindingMeta returns meta info of the appbinding which has been created by schema manager

func (*MariaDBDatabase) GetInit

func (in *MariaDBDatabase) GetInit() *InitSpec

func (*MariaDBDatabase) GetInitJobMeta added in v0.27.0

func (in *MariaDBDatabase) GetInitJobMeta() metav1.ObjectMeta

GetInitJobMeta returns meta info of the init job which has been created by schema manager

func (*MariaDBDatabase) GetMySQLAuthSecretMeta added in v0.27.0

func (in *MariaDBDatabase) GetMySQLAuthSecretMeta() metav1.ObjectMeta

GetMySQLAuthSecretMeta returns meta info of the mysql auth secret

func (*MariaDBDatabase) GetMySQLRoleMeta added in v0.27.0

func (in *MariaDBDatabase) GetMySQLRoleMeta() metav1.ObjectMeta

GetMySQLRoleMeta returns meta info of the MySQL role which has been created by schema manager

func (*MariaDBDatabase) GetRepositoryMeta added in v0.27.0

func (in *MariaDBDatabase) GetRepositoryMeta() metav1.ObjectMeta

GetRepositoryMeta returns meta info of the repository which has been created by schema manager

func (*MariaDBDatabase) GetRepositorySecretMeta added in v0.27.0

func (in *MariaDBDatabase) GetRepositorySecretMeta() metav1.ObjectMeta

GetRepositorySecretMeta returns meta info of the repository which has been created by schema manager

func (*MariaDBDatabase) GetRestoreSessionMeta added in v0.27.0

func (in *MariaDBDatabase) GetRestoreSessionMeta() metav1.ObjectMeta

GetRestoreSessionMeta returns meta info of the restore session which has been created by schema manager

func (*MariaDBDatabase) GetSecretAccessRequestMeta added in v0.27.0

func (in *MariaDBDatabase) GetSecretAccessRequestMeta() metav1.ObjectMeta

GetSecretAccessRequestMeta returns meta info of the secret access request which has been created by schema manager

func (*MariaDBDatabase) GetStatus

func (in *MariaDBDatabase) GetStatus() DatabaseStatus

func (*MariaDBDatabase) GetVaultSecretEngineMeta added in v0.27.0

func (in *MariaDBDatabase) GetVaultSecretEngineMeta() metav1.ObjectMeta

GetVaultSecretEngineMeta returns meta info of the secret engine which has been created by schema manager

func (*MariaDBDatabase) SetupWebhookWithManager added in v0.27.0

func (r *MariaDBDatabase) SetupWebhookWithManager(mgr manager.Manager) error

func (*MariaDBDatabase) ValidateCreate added in v0.27.0

func (r *MariaDBDatabase) ValidateCreate() error

ValidateCreate implements webhook.Validator so a webhook will be registered for the type

func (*MariaDBDatabase) ValidateDelete added in v0.27.0

func (r *MariaDBDatabase) ValidateDelete() error

ValidateDelete implements webhook.Validator so a webhook will be registered for the type

func (*MariaDBDatabase) ValidateMariaDBDatabase added in v0.27.0

func (in *MariaDBDatabase) ValidateMariaDBDatabase() error

func (*MariaDBDatabase) ValidateUpdate added in v0.27.0

func (r *MariaDBDatabase) ValidateUpdate(old runtime.Object) error

ValidateUpdate implements webhook.Validator so a webhook will be registered for the type

type MariaDBDatabaseConfiguration

type MariaDBDatabaseConfiguration struct {
	// Name is target database name
	Name string `json:"name"`

	// CharacterSet is the target database character set
	// +optional
	CharacterSet string `json:"characterSet,omitempty"`

	// Collation is the target database collation
	// +optional
	Collation string `json:"collation,omitempty"`

	// Comment is the additional comment to the mariadb Database
	// +optional
	Comment string `json:"comment,omitempty"`
}

func (*MariaDBDatabaseConfiguration) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MariaDBDatabaseConfiguration.

func (*MariaDBDatabaseConfiguration) DeepCopyInto

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type MariaDBDatabaseInfo

type MariaDBDatabaseInfo struct {
	// ServerRef refers to a KubeDB managed database instance
	ServerRef kmapi.ObjectReference `json:"serverRef"`

	// DatabaseConfig defines various configuration options for a database
	Config MariaDBDatabaseConfiguration `json:"config"`
}

func (*MariaDBDatabaseInfo) DeepCopy

func (in *MariaDBDatabaseInfo) DeepCopy() *MariaDBDatabaseInfo

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MariaDBDatabaseInfo.

func (*MariaDBDatabaseInfo) DeepCopyInto

func (in *MariaDBDatabaseInfo) DeepCopyInto(out *MariaDBDatabaseInfo)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type MariaDBDatabaseList

type MariaDBDatabaseList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []MariaDBDatabase `json:"items"`
}

+k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +kubebuilder:object:root=true

func (*MariaDBDatabaseList) DeepCopy

func (in *MariaDBDatabaseList) DeepCopy() *MariaDBDatabaseList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MariaDBDatabaseList.

func (*MariaDBDatabaseList) DeepCopyInto

func (in *MariaDBDatabaseList) DeepCopyInto(out *MariaDBDatabaseList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*MariaDBDatabaseList) DeepCopyObject

func (in *MariaDBDatabaseList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type MariaDBDatabaseSpec

type MariaDBDatabaseSpec struct {
	// Database defines various configuration options for a database
	Database MariaDBDatabaseInfo `json:"database"`

	// VaultRef refers to a KubeVault managed vault server
	VaultRef kmapi.ObjectReference `json:"vaultRef"`

	// AccessPolicy contains the serviceAccount details and TTL values of the vault-created secret
	AccessPolicy VaultSecretEngineRole `json:"accessPolicy"`

	// Init contains info about the init script or snapshot info
	// +optional
	Init *InitSpec `json:"init,omitempty"`

	// DeletionPolicy controls the delete operation for database
	// +optional
	// +kubebuilder:default="Delete"
	DeletionPolicy DeletionPolicy `json:"deletionPolicy,omitempty"`
}

MariaDBDatabaseSpec defines the desired state of MariaDBDatabase

func (*MariaDBDatabaseSpec) DeepCopy

func (in *MariaDBDatabaseSpec) DeepCopy() *MariaDBDatabaseSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MariaDBDatabaseSpec.

func (*MariaDBDatabaseSpec) DeepCopyInto

func (in *MariaDBDatabaseSpec) DeepCopyInto(out *MariaDBDatabaseSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type MongoDBDatabase

type MongoDBDatabase struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   MongoDBDatabaseSpec `json:"spec,omitempty"`
	Status DatabaseStatus      `json:"status,omitempty"`
}

+genclient +k8s:openapi-gen=true +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +kubebuilder:object:root=true +kubebuilder:resource:path=mongodbdatabases,singular=mongodbdatabase,shortName=mgschema,categories={datastore,kubedb,appscode,all} +kubebuilder:subresource:status +kubebuilder:printcolumn:name="DB_SERVER",type="string",JSONPath=".spec.database.serverRef.name" +kubebuilder:printcolumn:name="DB_NAME",type="string",JSONPath=".spec.database.config.name" +kubebuilder:printcolumn:name="Status",type="string",JSONPath=".status.phase" +kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp"

func (*MongoDBDatabase) CheckDoubleOptIn added in v0.27.0

func (in *MongoDBDatabase) CheckDoubleOptIn(ctx context.Context, client client.Client) (bool, error)

func (*MongoDBDatabase) CheckIfNameFieldsAreOkOrNot

func (in *MongoDBDatabase) CheckIfNameFieldsAreOkOrNot() *field.Error

func (MongoDBDatabase) CustomResourceDefinition

func (in MongoDBDatabase) CustomResourceDefinition() *apiextensions.CustomResourceDefinition

func (*MongoDBDatabase) DeepCopy

func (in *MongoDBDatabase) DeepCopy() *MongoDBDatabase

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MongoDBDatabase.

func (*MongoDBDatabase) DeepCopyInto

func (in *MongoDBDatabase) DeepCopyInto(out *MongoDBDatabase)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*MongoDBDatabase) DeepCopyObject

func (in *MongoDBDatabase) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*MongoDBDatabase) Default

func (in *MongoDBDatabase) Default()

Default implements webhook.Defaulter so a webhook will be registered for the type

func (*MongoDBDatabase) GetAuthSecretName

func (in *MongoDBDatabase) GetAuthSecretName(dbServerName string) string

func (*MongoDBDatabase) GetInit

func (in *MongoDBDatabase) GetInit() *InitSpec

func (*MongoDBDatabase) GetMongoAdminRoleName

func (in *MongoDBDatabase) GetMongoAdminRoleName() string

func (*MongoDBDatabase) GetMongoAdminSecretAccessRequestName

func (in *MongoDBDatabase) GetMongoAdminSecretAccessRequestName() string

func (*MongoDBDatabase) GetMongoAdminServiceAccountName

func (in *MongoDBDatabase) GetMongoAdminServiceAccountName() string

func (*MongoDBDatabase) GetMongoAppBindingName

func (in *MongoDBDatabase) GetMongoAppBindingName() string

func (*MongoDBDatabase) GetMongoInitJobName

func (in *MongoDBDatabase) GetMongoInitJobName() string

func (*MongoDBDatabase) GetMongoInitScriptContainerName

func (in *MongoDBDatabase) GetMongoInitScriptContainerName() string

func (*MongoDBDatabase) GetMongoInitVolumeNameForPod

func (in *MongoDBDatabase) GetMongoInitVolumeNameForPod() string

func (*MongoDBDatabase) GetMongoRestoreSessionName

func (in *MongoDBDatabase) GetMongoRestoreSessionName() string

func (*MongoDBDatabase) GetMongoSecretEngineName

func (in *MongoDBDatabase) GetMongoSecretEngineName() string

func (*MongoDBDatabase) GetStatus

func (in *MongoDBDatabase) GetStatus() DatabaseStatus

func (*MongoDBDatabase) SetupWebhookWithManager

func (in *MongoDBDatabase) SetupWebhookWithManager(mgr manager.Manager) error

func (*MongoDBDatabase) ValidateCreate

func (in *MongoDBDatabase) ValidateCreate() error

ValidateCreate implements webhook.Validator so a webhook will be registered for the type

func (*MongoDBDatabase) ValidateDelete

func (in *MongoDBDatabase) ValidateDelete() error

ValidateDelete implements webhook.Validator so a webhook will be registered for the type

func (*MongoDBDatabase) ValidateMongoDBDatabase

func (in *MongoDBDatabase) ValidateMongoDBDatabase() error

func (*MongoDBDatabase) ValidateUpdate

func (in *MongoDBDatabase) ValidateUpdate(old runtime.Object) error

ValidateUpdate implements webhook.Validator so a webhook will be registered for the type

type MongoDBDatabaseConfiguration

type MongoDBDatabaseConfiguration struct {
	Name string `json:"name"`
}

func (*MongoDBDatabaseConfiguration) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MongoDBDatabaseConfiguration.

func (*MongoDBDatabaseConfiguration) DeepCopyInto

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type MongoDBDatabaseInfo

type MongoDBDatabaseInfo struct {
	// ServerRef refers to a KubeDB managed database instance
	ServerRef kmapi.ObjectReference `json:"serverRef"`

	// DatabaseConfig defines various configuration options for a database
	Config MongoDBDatabaseConfiguration `json:"config"`
}

func (*MongoDBDatabaseInfo) DeepCopy

func (in *MongoDBDatabaseInfo) DeepCopy() *MongoDBDatabaseInfo

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MongoDBDatabaseInfo.

func (*MongoDBDatabaseInfo) DeepCopyInto

func (in *MongoDBDatabaseInfo) DeepCopyInto(out *MongoDBDatabaseInfo)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type MongoDBDatabaseList

type MongoDBDatabaseList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []MongoDBDatabase `json:"items"`
}

+k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +kubebuilder:object:root=true

func (*MongoDBDatabaseList) DeepCopy

func (in *MongoDBDatabaseList) DeepCopy() *MongoDBDatabaseList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MongoDBDatabaseList.

func (*MongoDBDatabaseList) DeepCopyInto

func (in *MongoDBDatabaseList) DeepCopyInto(out *MongoDBDatabaseList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*MongoDBDatabaseList) DeepCopyObject

func (in *MongoDBDatabaseList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type MongoDBDatabaseSpec

type MongoDBDatabaseSpec struct {
	// Database defines various configuration options for a database
	Database MongoDBDatabaseInfo `json:"database"`

	// VaultRef refers to a KubeVault managed vault server
	VaultRef kmapi.ObjectReference `json:"vaultRef"`

	// AccessPolicy contains the serviceAccount details and TTL values of the vault-created secret
	AccessPolicy VaultSecretEngineRole `json:"accessPolicy"`

	// Init contains info about the init script or snapshot info
	// +optional
	Init *InitSpec `json:"init,omitempty"`

	// DeletionPolicy controls the delete operation for database
	// +optional
	// +kubebuilder:default="Delete"
	DeletionPolicy DeletionPolicy `json:"deletionPolicy,omitempty"`
}

MongoDBDatabaseSpec defines the desired state of MongoDBDatabase

func (*MongoDBDatabaseSpec) DeepCopy

func (in *MongoDBDatabaseSpec) DeepCopy() *MongoDBDatabaseSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MongoDBDatabaseSpec.

func (*MongoDBDatabaseSpec) DeepCopyInto

func (in *MongoDBDatabaseSpec) DeepCopyInto(out *MongoDBDatabaseSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type MySQLDatabase

type MySQLDatabase struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   MySQLDatabaseSpec `json:"spec,omitempty"`
	Status DatabaseStatus    `json:"status,omitempty"`
}

+genclient +k8s:openapi-gen=true +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +kubebuilder:object:root=true +kubebuilder:resource:path=mysqldatabases,singular=mysqldatabase,shortName=myschema,categories={datastore,kubedb,appscode,all} +kubebuilder:subresource:status +kubebuilder:printcolumn:name="DB_SERVER",type="string",JSONPath=".spec.database.serverRef.name" +kubebuilder:printcolumn:name="DB_NAME",type="string",JSONPath=".spec.database.config.name" +kubebuilder:printcolumn:name="Status",type="string",JSONPath=".status.phase" +kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp"

func (*MySQLDatabase) CheckDoubleOptIn added in v0.27.0

func (in *MySQLDatabase) CheckDoubleOptIn(ctx context.Context, client client.Client) (bool, error)

func (MySQLDatabase) CustomResourceDefinition

func (in MySQLDatabase) CustomResourceDefinition() *apiextensions.CustomResourceDefinition

func (*MySQLDatabase) DeepCopy

func (in *MySQLDatabase) DeepCopy() *MySQLDatabase

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MySQLDatabase.

func (*MySQLDatabase) DeepCopyInto

func (in *MySQLDatabase) DeepCopyInto(out *MySQLDatabase)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*MySQLDatabase) DeepCopyObject

func (in *MySQLDatabase) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*MySQLDatabase) Default

func (in *MySQLDatabase) Default()

Default implements webhook.Defaulter so a webhook will be registered for the type

func (*MySQLDatabase) GetAppBindingMeta

func (in *MySQLDatabase) GetAppBindingMeta() metav1.ObjectMeta

GetAppBindingMeta returns meta info of the appbinding which has been created by schema manager

func (*MySQLDatabase) GetInit

func (in *MySQLDatabase) GetInit() *InitSpec

func (*MySQLDatabase) GetInitJobMeta

func (in *MySQLDatabase) GetInitJobMeta() metav1.ObjectMeta

GetInitJobMeta returns meta info of the init job which has been created by schema manager

func (*MySQLDatabase) GetMySQLAuthSecretMeta

func (in *MySQLDatabase) GetMySQLAuthSecretMeta() metav1.ObjectMeta

GetMySQLAuthSecretMeta returns meta info of the mysql auth secret

func (*MySQLDatabase) GetMySQLRoleMeta

func (in *MySQLDatabase) GetMySQLRoleMeta() metav1.ObjectMeta

GetMySQLRoleMeta returns meta info of the MySQL role which has been created by schema manager

func (*MySQLDatabase) GetRepositoryMeta

func (in *MySQLDatabase) GetRepositoryMeta() metav1.ObjectMeta

GetRepositoryMeta returns meta info of the repository which has been created by schema manager

func (*MySQLDatabase) GetRepositorySecretMeta

func (in *MySQLDatabase) GetRepositorySecretMeta() metav1.ObjectMeta

GetRepositorySecretMeta returns meta info of the repository which has been created by schema manager

func (*MySQLDatabase) GetRestoreSessionMeta

func (in *MySQLDatabase) GetRestoreSessionMeta() metav1.ObjectMeta

GetRestoreSessionMeta returns meta info of the restore session which has been created by schema manager

func (*MySQLDatabase) GetSecretAccessRequestMeta

func (in *MySQLDatabase) GetSecretAccessRequestMeta() metav1.ObjectMeta

GetSecretAccessRequestMeta returns meta info of the secret access request which has been created by schema manager

func (*MySQLDatabase) GetStatus

func (in *MySQLDatabase) GetStatus() DatabaseStatus

func (*MySQLDatabase) GetVaultSecretEngineMeta

func (in *MySQLDatabase) GetVaultSecretEngineMeta() metav1.ObjectMeta

GetVaultSecretEngineMeta returns meta info of the secret engine which has been created by schema manager

func (*MySQLDatabase) SetupWebhookWithManager

func (in *MySQLDatabase) SetupWebhookWithManager(mgr manager.Manager) error

func (*MySQLDatabase) ValidateCreate

func (in *MySQLDatabase) ValidateCreate() error

ValidateCreate implements webhook.Validator so a webhook will be registered for the type

func (*MySQLDatabase) ValidateDelete

func (in *MySQLDatabase) ValidateDelete() error

ValidateDelete implements webhook.Validator so a webhook will be registered for the type

func (*MySQLDatabase) ValidateMySQLDatabase

func (in *MySQLDatabase) ValidateMySQLDatabase() error

func (*MySQLDatabase) ValidateUpdate

func (in *MySQLDatabase) ValidateUpdate(old runtime.Object) error

ValidateUpdate implements webhook.Validator so a webhook will be registered for the type

type MySQLDatabaseConfiguration

type MySQLDatabaseConfiguration struct {
	// Name is target database name
	Name string `json:"name"`

	// CharacterSet is the target database character set
	// +optional
	CharacterSet string `json:"characterSet,omitempty"`

	// Collation is the target database collation
	// +optional
	Collation string `json:"collation,omitempty"`

	// Encryption is the target databae encryption mode
	// +optional
	Encryption string `json:"encryption,omitempty"`

	// ReadOnly is the target database read only mode
	// +optional
	ReadOnly int32 `json:"readOnly,omitempty"`
}

func (*MySQLDatabaseConfiguration) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MySQLDatabaseConfiguration.

func (*MySQLDatabaseConfiguration) DeepCopyInto

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type MySQLDatabaseInfo

type MySQLDatabaseInfo struct {
	// ServerRef refers to a KubeDB managed database instance
	ServerRef kmapi.ObjectReference `json:"serverRef"`

	// DatabaseConfig defines various configuration options for a database
	Config MySQLDatabaseConfiguration `json:"config"`
}

func (*MySQLDatabaseInfo) DeepCopy

func (in *MySQLDatabaseInfo) DeepCopy() *MySQLDatabaseInfo

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MySQLDatabaseInfo.

func (*MySQLDatabaseInfo) DeepCopyInto

func (in *MySQLDatabaseInfo) DeepCopyInto(out *MySQLDatabaseInfo)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type MySQLDatabaseList

type MySQLDatabaseList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []MySQLDatabase `json:"items"`
}

+k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +kubebuilder:object:root=true

func (*MySQLDatabaseList) DeepCopy

func (in *MySQLDatabaseList) DeepCopy() *MySQLDatabaseList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MySQLDatabaseList.

func (*MySQLDatabaseList) DeepCopyInto

func (in *MySQLDatabaseList) DeepCopyInto(out *MySQLDatabaseList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*MySQLDatabaseList) DeepCopyObject

func (in *MySQLDatabaseList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type MySQLDatabaseSpec

type MySQLDatabaseSpec struct {
	// Database defines various configuration options for a database
	Database MySQLDatabaseInfo `json:"database"`

	// VaultRef refers to a KubeVault managed vault server
	VaultRef kmapi.ObjectReference `json:"vaultRef"`

	// AccessPolicy contains the serviceAccount details and TTL values of the vault-created secret
	AccessPolicy VaultSecretEngineRole `json:"accessPolicy"`

	// Init contains info about the init script or snapshot info
	// +optional
	Init *InitSpec `json:"init,omitempty"`

	// DeletionPolicy controls the delete operation for database
	// +optional
	// +kubebuilder:default="Delete"
	DeletionPolicy DeletionPolicy `json:"deletionPolicy,omitempty"`
}

MySQLDatabaseSpec defines the desired state of MySQLDatabase

func (*MySQLDatabaseSpec) DeepCopy

func (in *MySQLDatabaseSpec) DeepCopy() *MySQLDatabaseSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MySQLDatabaseSpec.

func (*MySQLDatabaseSpec) DeepCopyInto

func (in *MySQLDatabaseSpec) DeepCopyInto(out *MySQLDatabaseSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Param

type Param struct {
	ConfigParameter string  `json:"configParameter"`
	Value           *string `json:"value"`
}

func (*Param) DeepCopy

func (in *Param) DeepCopy() *Param

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Param.

func (*Param) DeepCopyInto

func (in *Param) DeepCopyInto(out *Param)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PostgresDatabase

type PostgresDatabase struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   PostgresDatabaseSpec `json:"spec,omitempty"`
	Status DatabaseStatus       `json:"status,omitempty"`
}

+genclient +k8s:openapi-gen=true +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +kubebuilder:object:root=true +kubebuilder:resource:path=postgresdatabases,singular=postgresdatabase,shortName=pgschema,categories={datastore,kubedb,appscode,all} +kubebuilder:subresource:status +kubebuilder:printcolumn:name="DB_SERVER",type="string",JSONPath=".spec.database.serverRef.name" +kubebuilder:printcolumn:name="DB_NAME",type="string",JSONPath=".spec.database.config.name" +kubebuilder:printcolumn:name="Status",type="string",JSONPath=".status.phase" +kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp"

func (*PostgresDatabase) CheckDoubleOptIn added in v0.27.0

func (in *PostgresDatabase) CheckDoubleOptIn(ctx context.Context, client client.Client) (bool, error)

func (PostgresDatabase) CustomResourceDefinition

func (_ PostgresDatabase) CustomResourceDefinition() *apiextensions.CustomResourceDefinition

func (*PostgresDatabase) DeepCopy

func (in *PostgresDatabase) DeepCopy() *PostgresDatabase

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PostgresDatabase.

func (*PostgresDatabase) DeepCopyInto

func (in *PostgresDatabase) DeepCopyInto(out *PostgresDatabase)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*PostgresDatabase) DeepCopyObject

func (in *PostgresDatabase) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*PostgresDatabase) Default

func (r *PostgresDatabase) Default()

Default implements webhook.Defaulter so a webhook will be registered for the type

func (*PostgresDatabase) GetInit

func (in *PostgresDatabase) GetInit() *InitSpec

func (*PostgresDatabase) GetStatus

func (in *PostgresDatabase) GetStatus() DatabaseStatus

func (*PostgresDatabase) SetupWebhookWithManager

func (r *PostgresDatabase) SetupWebhookWithManager(mgr ctrl.Manager) error

func (*PostgresDatabase) ValidateCreate

func (r *PostgresDatabase) ValidateCreate() error

ValidateCreate implements webhook.Validator so a webhook will be registered for the type

func (*PostgresDatabase) ValidateDelete

func (r *PostgresDatabase) ValidateDelete() error

ValidateDelete implements webhook.Validator so a webhook will be registered for the type

func (*PostgresDatabase) ValidateFields

func (r *PostgresDatabase) ValidateFields() *field.Error

func (*PostgresDatabase) ValidateParams

func (r *PostgresDatabase) ValidateParams() *field.Error

func (*PostgresDatabase) ValidatePostgresDBName

func (r *PostgresDatabase) ValidatePostgresDBName() *field.Error

func (*PostgresDatabase) ValidatePostgresDatabase

func (r *PostgresDatabase) ValidatePostgresDatabase() error

func (*PostgresDatabase) ValidatePostgresDatabaseUpdate

func (r *PostgresDatabase) ValidatePostgresDatabaseUpdate(oldobj *PostgresDatabase, newobj *PostgresDatabase) error

func (*PostgresDatabase) ValidateReadOnly

func (r *PostgresDatabase) ValidateReadOnly() *field.Error

func (*PostgresDatabase) ValidateSchemaInitRestore

func (r *PostgresDatabase) ValidateSchemaInitRestore() *field.Error

func (*PostgresDatabase) ValidateUpdate

func (r *PostgresDatabase) ValidateUpdate(old runtime.Object) error

ValidateUpdate implements webhook.Validator so a webhook will be registered for the type

type PostgresDatabaseConfiguration

type PostgresDatabaseConfiguration struct {
	Name   string  `json:"name"`
	Params []Param `json:"params,omitempty"`
}

func (*PostgresDatabaseConfiguration) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PostgresDatabaseConfiguration.

func (*PostgresDatabaseConfiguration) DeepCopyInto

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PostgresDatabaseInfo

type PostgresDatabaseInfo struct {
	// ServerRef refers to a KubeDB managed database instance
	ServerRef kmapi.ObjectReference `json:"serverRef"`

	// DatabaseConfig defines various configuration options for a database
	Config PostgresDatabaseConfiguration `json:"config"`
}

func (*PostgresDatabaseInfo) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PostgresDatabaseInfo.

func (*PostgresDatabaseInfo) DeepCopyInto

func (in *PostgresDatabaseInfo) DeepCopyInto(out *PostgresDatabaseInfo)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PostgresDatabaseList

type PostgresDatabaseList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []PostgresDatabase `json:"items"`
}

+k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +kubebuilder:object:root=true

func (*PostgresDatabaseList) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PostgresDatabaseList.

func (*PostgresDatabaseList) DeepCopyInto

func (in *PostgresDatabaseList) DeepCopyInto(out *PostgresDatabaseList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*PostgresDatabaseList) DeepCopyObject

func (in *PostgresDatabaseList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type PostgresDatabaseSpec

type PostgresDatabaseSpec struct {
	// Database defines various configuration options for a database
	Database PostgresDatabaseInfo `json:"database"`

	// VaultRef refers to a KubeVault managed vault server
	VaultRef kmapi.ObjectReference `json:"vaultRef"`

	// AccessPolicy contains the serviceAccount details and TTL values of the vault-created secret
	AccessPolicy VaultSecretEngineRole `json:"accessPolicy"`

	// Init contains info about the init script or snapshot info
	// +optional
	Init *InitSpec `json:"init,omitempty"`

	// DeletionPolicy controls the delete operation for database
	// +optional
	// +kubebuilder:default="Delete"
	DeletionPolicy DeletionPolicy `json:"deletionPolicy,omitempty"`
}

PostgresDatabaseSpec defines the desired state of PostgresDatabase

func (*PostgresDatabaseSpec) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PostgresDatabaseSpec.

func (*PostgresDatabaseSpec) DeepCopyInto

func (in *PostgresDatabaseSpec) DeepCopyInto(out *PostgresDatabaseSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ScriptSourceSpec

type ScriptSourceSpec struct {
	ScriptPath        string `json:"scriptPath,omitempty"`
	core.VolumeSource `json:",inline,omitempty"`
	// This will take some database related config from the user
	PodTemplate *core.PodTemplateSpec `json:"podTemplate,omitempty"`
}

func (*ScriptSourceSpec) DeepCopy

func (in *ScriptSourceSpec) DeepCopy() *ScriptSourceSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ScriptSourceSpec.

func (*ScriptSourceSpec) DeepCopyInto

func (in *ScriptSourceSpec) DeepCopyInto(out *ScriptSourceSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type SnapshotSourceSpec

type SnapshotSourceSpec struct {
	Repository kmapi.TypedObjectReference `json:"repository,omitempty"`
	// +kubebuilder:default="latest"
	SnapshotID string `json:"snapshotID,omitempty"`
}

func (*SnapshotSourceSpec) DeepCopy

func (in *SnapshotSourceSpec) DeepCopy() *SnapshotSourceSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SnapshotSourceSpec.

func (*SnapshotSourceSpec) DeepCopyInto

func (in *SnapshotSourceSpec) DeepCopyInto(out *SnapshotSourceSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type VaultSecretEngineRole

type VaultSecretEngineRole struct {
	Subjects []rbac.Subject `json:"subjects"`
	// +optional
	DefaultTTL string `json:"defaultTTL,omitempty"`
	// +optional
	MaxTTL string `json:"maxTTL,omitempty"`
}

func (*VaultSecretEngineRole) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VaultSecretEngineRole.

func (*VaultSecretEngineRole) DeepCopyInto

func (in *VaultSecretEngineRole) DeepCopyInto(out *VaultSecretEngineRole)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

Jump to

Keyboard shortcuts

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