Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddToManager ¶
func AddToManager(ctx *pkgctx.ControllerManagerContext, mgr ctrlmgr.Manager) error
AddToManager adds the webhook to the provided manager.
func NewMutator ¶
func NewMutator(client ctrlclient.Client) builder.Mutator
NewMutator returns the package's Mutator.
func ProcessPowerState ¶
func ProcessPowerState( ctx *pkgctx.WebhookRequestContext, newVMG, oldVMG *vmopv1.VirtualMachineGroup) (bool, error)
ProcessPowerState updates the last updated power state time annotation to the current UTC time in RFC3339Nano format for the following cases: 1. The group is created with a non-empty spec.powerState value. 2. The spec.powerState is updated. 3. The spec.nextForcePowerStateSyncTime is set to "now". It also removes the apply power state change time annotation if the group is being updated directly (not inherited from a parent).
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.