Documentation
¶
Index ¶
Constants ¶
const ( RbacObjCtxKey = rbacObjCtxKey("RbacObjects") RbacObjNamePrefix = "sts-resize-sync-job-" )
const ManagedLabel = "sts-resize.vshn.net/managed"
ManagedLabel is a label to mark resources to be managed by the controller
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CriticalError ¶
CriticalError is an unrecoverable error.
func (CriticalError) Error ¶
func (err CriticalError) Error() string
Error implements the Error interface
func (*CriticalError) Unwrap ¶
func (err *CriticalError) Unwrap() error
Unwrap is used to make it work with errors.Is, errors.As.
type InplaceReconciler ¶ added in v0.3.0
type InplaceReconciler struct {
client.Client
Scheme *runtime.Scheme
Recorder record.EventRecorder
RequeueAfter time.Duration
LabelName string
}
InplaceReconciler reconciles a StatefulSet object It will resize the PVCs according to the sts template.
func (*InplaceReconciler) Reconcile ¶ added in v0.3.0
Reconcile is the main work loop, reacting to changes in statefulsets and initiating resizing of StatefulSets.
func (*InplaceReconciler) SetupWithManager ¶ added in v0.3.0
func (r *InplaceReconciler) SetupWithManager(mgr ctrl.Manager) error
SetupWithManager sets up the controller with the Manager.
type RbacObjects ¶ added in v0.2.0
type RbacObjects struct {
Name string
ServiceAccount corev1.ServiceAccount
RoleBinding rbacv1.RoleBinding
Created bool
}
type StatefulSetController ¶ added in v0.3.0
StatefulSetController is an interface for various implementations of the StatefulSet controller.
type StatefulSetReconciler ¶
type StatefulSetReconciler struct {
client.Client
Scheme *runtime.Scheme
Recorder record.EventRecorder
SyncContainerImage string
SyncClusterRole string
RequeueAfter time.Duration
}
StatefulSetReconciler reconciles a StatefulSet object
func (*StatefulSetReconciler) Reconcile ¶
func (r *StatefulSetReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)
Reconcile is the main work loop, reacting to changes in statefulsets and initiating resizing of StatefulSets.
func (*StatefulSetReconciler) SetupWithManager ¶
func (r *StatefulSetReconciler) SetupWithManager(mgr ctrl.Manager) error
SetupWithManager sets up the controller with the Manager.