Version: v0.0.0-...-0e8cb4b Latest Latest

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

Go to latest
Published: Jun 1, 2023 License: Apache-2.0 Imports: 40 Imported by: 0




View Source
const (
	BackupStatePreparingToStart = "PreparingToStart"
	BackupStateStarting         = "Starting"
	BackupStateActive           = "Active"
	BackupStateSucceeded        = "Succeeded"
	BackupStateTimeout          = "BackupTimeout"
	BackupStateError            = "UnrecoverableError"

Backup states

View Source
const (
	PrecacheStateNotStarted       = "NotStarted"
	PrecacheStatePreparingToStart = "PreparingToStart"
	PrecacheStateStarting         = "Starting"
	PrecacheStateActive           = "Active"
	PrecacheStateSucceeded        = "Succeeded"
	PrecacheStateTimeout          = "PrecacheTimeout"
	PrecacheStateError            = "UnrecoverableError"

Pre-cache states

View Source
const (
	NoNsView                   = "NoNsView"
	NoNsFoundOnSpoke           = "NoNsFoundOnSpoke"
	NsFoundOnSpoke             = "NsFoundOnSpoke"
	NoJobView                  = "NoJobView"
	NoJobFoundOnSpoke          = "NoJobFoundOnSpoke"
	JobViewExists              = "JobViewExists"
	DependenciesViewNotPresent = "DependenciesViewNotPresent"
	DependenciesNotPresent     = "DependenciesNotPresent"
	JobDeadline                = "JobDeadline"
	JobSucceeded               = "JobSucceeded"
	JobActive                  = "JobActive"
	JobBackoffLimitExceeded    = "JobBackoffLimitExceeded"
	UnforeseenCondition        = "UnforeseenCondition"

Jobresources conditions


This section is empty.


This section is empty.


type ClusterGroupUpgradeReconciler

type ClusterGroupUpgradeReconciler struct {
	Log      logr.Logger
	Scheme   *runtime.Scheme
	Recorder record.EventRecorder

ClusterGroupUpgradeReconciler reconciles a ClusterGroupUpgrade object

func (*ClusterGroupUpgradeReconciler) Reconcile

func (r *ClusterGroupUpgradeReconciler) Reconcile(ctx context.Context, req ctrl.Request) (nextReconcile ctrl.Result, err error)

Reconcile is part of the main kubernetes reconciliation loop which aims to move the current state of the cluster closer to the desired state. TODO(user): Modify the Reconcile function to compare the state specified by the ClusterGroupUpgrade object against the actual cluster state, and then perform operations to make the cluster state reflect the state specified by the user.

For more details, check Reconcile and its Result here: -

func (*ClusterGroupUpgradeReconciler) SetupWithManager

func (r *ClusterGroupUpgradeReconciler) SetupWithManager(mgr ctrl.Manager) error

SetupWithManager sets up the controller with the Manager.

type ConfigurationObject

type ConfigurationObject struct {
	Kind       string  `json:"kind,omitempty"`
	Name       string  `json:"name,omitempty"`
	APIVersion string  `json:"apiVersion,omitempty"`
	Namespace  *string `json:"namespace,omitempty"`

ConfigurationObject defines the details of an object configured through a Policy

type ManagedClusterForCguReconciler

type ManagedClusterForCguReconciler struct {
	Log    logr.Logger
	Scheme *runtime.Scheme

ManagedClusterForCguReconciler reconciles a ManagedCluster object to auto create the ClusterGroupUpgrade

func (*ManagedClusterForCguReconciler) Reconcile

Reconcile the managed cluster auto create ClusterGroupUpgrade

  • Controller watches for create event of managed cluster object. Reconciliation is triggered when a new managed cluster is created
  • When a new managed cluster is created, create ClusterGroupUpgrade CR for the cluster only when it's ready and its child policies are available
  • As created ClusterGroupUpgrade has ownReference set to its managed cluster, when the managed cluster is deleted, the ClusterGroupUpgrade will be auto-deleted

Note: The Controller will requeue the Request to be processed again if the returned error is non-nil or Result.Requeue is true, otherwise upon completion it will remove the work from the queue.

func (*ManagedClusterForCguReconciler) SetupWithManager

func (r *ManagedClusterForCguReconciler) SetupWithManager(mgr ctrl.Manager) error

SetupWithManager sets up the controller with the Manager.


Path Synopsis

Jump to

Keyboard shortcuts

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