-
Story
-
Resolution: Done
-
Critical
-
None
-
None
-
None
-
None
-
3
-
False
-
-
False
-
Agent Sprint 221
The agent-config.yaml file has a field for setting a host's role to either master or worker.
The client binary created in AGENT-229 will read roles from files named /etc/assisted/hostconfig/*/role and apply them to the assisted API.
We need to pass that data from the agent-config into the files at the correct locations in the ISO. This requires code equivalent to https://github.com/openshift/installer/commit/ace389bce08a6ababa5ea9d8304559de88e8170d (which did the same for Root Device Hints).
We also need to pre-validate that the settings we have are sane:
- If all hosts are masters there must be exactly 3 of them
- If at least 3 masters, there must be 2 other nodes that can be workers
- If only 1 node, it cannot be a worker
- Node0 (i.e. host with rendezvous IP) cannot be a worker, and should be treated as a master for the purpose of validations above. (We can't really infer which host is node0 until we have NMState in the agent-config file though. When we fallback to selecting a host to be Node0 we could take into account which hosts are potential masters and select one of them.)
- Probably others?