File tree Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -64,6 +64,12 @@ const (
6464 FinalizerDeleteInstance = "machine-delete-finalizer"
6565 FinalizerDeleteNode = "machine-node-delete-finalizer"
6666
67+ // AnnotationMachineUninitialized indicates that a machine is not yet
68+ // ready to be worked on by the machine-controller. The machine-controller
69+ // will ignore all machines that have this anotation with any value
70+ // Its value should consist of one or more initializers, separated by a comma
71+ AnnotationMachineUninitialized = "machine-controller.kubermatic.io/initializers"
72+
6773 deletionRetryWaitPeriod = 10 * time .Second
6874
6975 NodeOwnerLabelName = "machine-controller/owned-by"
@@ -356,6 +362,12 @@ func (c *Controller) syncHandler(key string) error {
356362 }
357363 return err
358364 }
365+
366+ if listerMachine .Annotations [AnnotationMachineUninitialized ] != "" {
367+ glog .V (4 ).Infof ("Ignoring machine %q because it has a non-emtpy %q annotation" , listerMachine .Name , AnnotationMachineUninitialized )
368+ return nil
369+ }
370+
359371 machine := listerMachine .DeepCopy ()
360372
361373 // This must stay in the controller, it can not be moved into the webhook
You can’t perform that action at this time.
0 commit comments