Description of problem: When attempting to create a new MachineConfigPool from console , the template has a spec.machineSelector key for selecting the nodes to match. Additionally, The MachineConfigPool view from the console displays a MachineSelector. However, this key is not recognised by the API, but the correct one for selecting a Node is actually spec.nodeSelector. Version-Release number of selected component (if applicable): 4.x.x How reproducible: Create a new MachineConfigPool from GUI Steps to Reproduce: 1. Template will present a spec.machineSelector key 2. GUI will also display a Machine Selector which seem to work correctly Actual results: MachineConfigPool doesn't match any node Expected results: MachineConfigPool should match the node Fix: - replace machineSelector with nodeSelector for the MachineConfigPool template and for the GUI view. Additional info: The node is selected by spec.NodeSelector: https://github.com/openshift/machine-config-operator/blob/f4bf2f4cf8a37a63436877efb397e98f4ef2124d/docs/MachineConfigController.md
This should be a small change from the console side: $ rg machineSelector public/models/yaml-templates.ts 1010: machineSelector: public/components/machine-config-pool.tsx 158: const machineSelector = _.get(obj, 'spec.machineSelector'); 167: <Selector kind={nodeReference} selector={machineSelector} /> public/module/k8s/index.ts 669: machineSelector?: Selector;
Checked on OCP 4.5 cluster with payload 4.5.0-0.nightly-2020-04-08-194554. 1. Go to "Compute" -> "Machine Config Pools" page, click into "master" mcp, check the yaml, there is " nodeSelector: matchLabels: node-role.kubernetes.io/master: '' " And on the detail page, the Node Selector field shows "node-role.kubernetes.io/master". 2. Create mcp with default example yaml, there is also nodeselector in the yaml template: nodeSelector: matchLabels: node-role.kubernetes.io/master: '' After create with default yaml, the "Node Selector" field shows "node-role.kubernetes.io/master", click on it, will go to search page with related nodes filtered out. The bug is fixed, so move it to Verified.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2020:2409