Documentation ¶
Index ¶
- Constants
- func DbDatabaseJob(database *databasev1beta1.MariaDBDatabase, databaseHostName string, ...) (*batchv1.Job, error)
- func DbInitJob(db *databasev1beta1.MariaDB) *batchv1.Job
- func DeleteDbDatabaseJob(database *databasev1beta1.MariaDBDatabase, databaseHostName string, ...) (*batchv1.Job, error)
- func Endpoints(db *databasev1beta1.MariaDB) *corev1.Endpoints
- func EndpointsForAdoption(db metav1.Object, adoption *databasev1beta1.AdoptionRedirectSpec) *corev1.Endpoints
- func ExecInPod(ctx context.Context, h *helper.Helper, config *rest.Config, namespace string, ...) error
- func GetLabels(name string) map[string]string
- func HeadlessService(db metav1.Object) *corev1.Service
- func LabelSelectors(database metav1.Object, dbType string) map[string]string
- func Pod(db *databasev1beta1.MariaDB, configHash string) *corev1.Pod
- func Pvc(db *databasev1beta1.MariaDB) *corev1.PersistentVolumeClaim
- func ResourceName(name string) string
- func Service(db *databasev1beta1.MariaDB) *corev1.Service
- func ServiceForAdoption(db metav1.Object, dbType string, ...) *corev1.Service
- func ServiceLabels(database metav1.Object) map[string]string
- func StatefulSet(g *mariadbv1.Galera) *appsv1.StatefulSet
- func StatefulSetLabels(database metav1.Object) map[string]string
- func StatefulSetName(name string) string
Constants ¶
const (
// ServiceName -
ServiceName = "mariadb"
)
Variables ¶
This section is empty.
Functions ¶
func DbDatabaseJob ¶
func DbDatabaseJob(database *databasev1beta1.MariaDBDatabase, databaseHostName string, databaseSecret string, containerImage string, serviceAccountName string) (*batchv1.Job, error)
DbDatabaseJob -
func DeleteDbDatabaseJob ¶
func DeleteDbDatabaseJob(database *databasev1beta1.MariaDBDatabase, databaseHostName string, databaseSecret string, containerImage string, serviceAccountName string) (*batchv1.Job, error)
DeleteDbDatabaseJob -
func EndpointsForAdoption ¶
func EndpointsForAdoption(db metav1.Object, adoption *databasev1beta1.AdoptionRedirectSpec) *corev1.Endpoints
EndpointsForAdoption - create an endpoint based on the adoption configuration
func ExecInPod ¶
func ExecInPod(ctx context.Context, h *helper.Helper, config *rest.Config, namespace string, pod string, container string, cmd []string, fun func(*bytes.Buffer, *bytes.Buffer) error) error
ExecInPod - execs a command in a running pod and pass its output to a callback function
func HeadlessService ¶
HeadlessService - service to give galera pods connectivity via DNS
func LabelSelectors ¶
LabelSelectors - labels for service, match statefulset and service should match
func Pvc ¶
func Pvc(db *databasev1beta1.MariaDB) *corev1.PersistentVolumeClaim
Pvc - Returns the deployment object for the Database
func ResourceName ¶
ResourceName - subresource name from a galera CR
func ServiceForAdoption ¶
func ServiceForAdoption(db metav1.Object, dbType string, adoption *databasev1beta1.AdoptionRedirectSpec) *corev1.Service
ServiceForAdoption - create a service based on the adoption configuration
func ServiceLabels ¶
ServiceLabels - labels for service, match statefulset labels
func StatefulSet ¶
func StatefulSet(g *mariadbv1.Galera) *appsv1.StatefulSet
StatefulSet returns a StatefulSet object for the galera cluster
func StatefulSetLabels ¶
StatefulSetLabels - labels for statefulset, match service labels
func StatefulSetName ¶
StatefulSetName - statefulset name from a galera CR
Types ¶
This section is empty.