Skip to content

Commit

Permalink
Merge pull request #3846 from sairameshv/OCPBUGS-17433
Browse files Browse the repository at this point in the history
OCPBUGS-17433: Sync featuregate controller during the node config controller sync
  • Loading branch information
openshift-merge-robot committed Aug 11, 2023
2 parents 4048c66 + 1b56ad7 commit 63d7be1
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/controller/kubelet-config/kubelet_config_features.go
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ func generateKubeConfigIgnFromFeatures(cc *mcfgv1.ControllerConfig, templatesDir
if err != nil {
return nil, err
}
if nodeConfig != nil {
if nodeConfig != nil && role == ctrlcommon.MachineConfigPoolWorker {
updateOriginalKubeConfigwithNodeConfig(nodeConfig, originalKubeConfig)
}

Expand Down
8 changes: 8 additions & 0 deletions pkg/controller/kubelet-config/kubelet_config_nodes.go
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,14 @@ func (ctrl *Controller) syncNodeConfigHandler(key string) error {
}
}

// syncing the featuregate controller
features, err := ctrl.featLister.Get(ctrlcommon.ClusterFeatureInstanceName)
if err == nil {
err := ctrl.syncFeatureHandler(features.Name)
if err != nil {
return fmt.Errorf("could not sync featuregate controller %v, err: %w", features, err)
}
}
return nil
}

Expand Down

0 comments on commit 63d7be1

Please sign in to comment.