System tests for k8s deploy have incorrect check for etcd nodes number

Bug #1619738 reported by Dennis Dmitriev
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
fuel-ccp
Confirmed
Medium
Fuel CCP Bug Team

Bug Description

Steps to reproduce:

1. Create a fuel-devops YAML template for 5 nodes (default.yaml have only 3 nodes)
2. Use it for run fuel-ccp-tests:
export CONF_PATH="default_5_nodes.yaml"
...
py.test fuel_ccp_tests/tests/system/test_ccp_install_k8s.py::TestFuelCCPInstaller::test_k8s_installed_default

Expected result:
- test passed

Actual result:
- deploy passed, but check for etcd nodes failed:

    def check_etcd_health(self, underlay):
        node_names = underlay.node_names()
        cmd = "etcdctl cluster-health | grep -c 'got healthy result'"

        etcd_nodes = underlay.sudo_check_call(
            cmd, node_name=node_names[0])['stdout'][0]
> assert int(etcd_nodes) == len(node_names),\
            "Number of etcd nodes is {0}," \
            " should be {1}".format(int(etcd_nodes), len(node_names))
E AssertionError: Number of etcd nodes is 3, should be 5
E assert 3 == 5
E + where 3 = int('3\n')
E + and 5 = len(['node-1', 'node-2', 'node-3', 'node-4', 'node-5'])

------------
Possible solution:
It is impossible to set necessary amount of 'etcd' nodes before deploy (see the bug https://bugs.launchpad.net/fuel-ccp/+bug/1619735), so the necessary information can be taken from the inventory.cfg, that was used for deploy, on the kube master node:

$ /home/vagrant/workspace/inventory/inventory.cfg

Changed in fuel-ccp:
status: New → In Progress
status: In Progress → Confirmed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.