Skip to content

Commit

Permalink
OpenShift: Fix deploying 2 SNOs (#781)
Browse files Browse the repository at this point in the history
When we are deploying OpenShift of baremetal, for example with 3 master
(control plane) nodes, kcli incorrectly deploys 2 nodes the
{cluster}-sno.iso image and 1 with the {cluster}-ctlplane.iso image.

This happens because we are doing an incorrect check on the index when
iterating over the baremeta_hosts.

This patch fixes this, so that only the first host uses the
{cluster}-sno.iso image.
  • Loading branch information
Akrog authored Feb 3, 2025
1 parent be885c6 commit 2283c67
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion kvirt/common/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2194,7 +2194,7 @@ def start_baremetal_hosts_with_iso(hosts, iso_url, overrides={}, debug=False):
or overrides.get('bmc_password')
if url is not None and user is not None and password is not None:
overrides['iso_url'] = iso_url
overrides['sno_worker'] = index > 1 and iso_url.endswith('-sno.iso')
overrides['sno_worker'] = index >= 1 and iso_url.endswith('-sno.iso')
result = start_baremetal_host(url, user, password, overrides=overrides, debug=debug)
if result['result'] != 'success':
failures.append(result['reason'])
Expand Down

0 comments on commit 2283c67

Please sign in to comment.