浏览代码

Fix bug when warning on no dedicated nodes.

Devan Goodwin 9 年之前
父节点
当前提交
e796856c80
共有 1 个文件被更改,包括 2 次插入3 次删除
  1. 2 3
      utils/src/ooinstall/cli_installer.py

+ 2 - 3
utils/src/ooinstall/cli_installer.py

@@ -343,9 +343,8 @@ https://docs.openshift.org/latest/install_config/install/advanced_install.html#m
             click.echo(message)
             click.echo(message)
             sys.exit(1)
             sys.exit(1)
 
 
-    nodes = [host for host in oo_cfg.hosts if host.node]
-    # TODO: This looks a little unsafe, maybe look for dedicated nodes only:
-    if len(masters) == len(nodes):
+    dedicated_nodes = [host for host in oo_cfg.hosts if host.node and not host.master]
+    if len(dedicated_nodes) == 0:
         message = """
         message = """
 WARNING: No dedicated Nodes specified. By default, colocated Masters have
 WARNING: No dedicated Nodes specified. By default, colocated Masters have
 their Nodes set to unscheduleable.  If you proceed all nodes will be labelled
 their Nodes set to unscheduleable.  If you proceed all nodes will be labelled