tripleo-validation --static-inventory parameter not working.

Bug #1912377 reported by Sofer Athlan-Guyot
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
tripleo
Fix Released
High
mathieu bultel

Bug Description

Hi,

In the help we have this:

  --static-inventory STATIC_INVENTORY
                        Provide your own static inventory file. You can
                        generate such an inventory calling tripleo-ansible-
                        inventory command. Especially useful when heat service
                        isn't available. (default: )

for the tripleo validator run command.

But, it doesn't work as expected. Static-inventory take a "string inventory" not an inventory file path.

This can be seen in the following command:

Using a file path:

[stack@undercloud-0 ~]$ openstack --os-cloud undercloud tripleo validator run --group no-op --static-inventory ./inventory.yaml

fails:

[WARNING]: Unable to parse /var/log/validations/artifacts/d2c68242-7865-41ef-
aacf-5b519e26328f_no-op.yaml_2021-01-19T17:23:28.604267Z/inventory.yaml as an
inventory source
[WARNING]: No inventory was parsed, only implicit localhost is available
[WARNING]: provided hosts list is empty, only localhost is available. Note that
the implicit localhost does not match 'all'
+--------------------------------------+-------------+--------+------------+----------------+-------------------+----------+
| UUID | Validations | Status | Host_Group | Status_by_Host | Unreachable_Hosts | Duration |
+--------------------------------------+-------------+--------+------------+----------------+-------------------+----------+
| d2c68242-7865-41ef-aacf-5b519e26328f | no-op | PASSED | all | | | |
+--------------------------------------+-------------+--------+------------+----------------+-------------------+----------+
[stack@undercloud-0 ~]$

Using an "inventory string":

openstack --os-cloud undercloud tripleo validator run --group no-op --static-inventory "$(cat ./inventory.yaml )"

works:

[WARNING]: Invalid characters were found in group names but not replaced, use
-vvvv to see details
Tuesday 19 January 2021 17:24:07 +0000 (0:00:00.040) 0:00:00.040 *******

Tuesday 19 January 2021 17:24:07 +0000 (0:00:00.216) 0:00:00.257 *******
===============================================================================
no_op : Run a no-op validation everywhere ------------------------------- 0.22s
+--------------------------------------+-------------+--------+------------+----------------------------------------------------------------------------------------------------+-------------------+-------------+
| UUID | Validations | Status | Host_Group | Status_by_Host | Unreachable_Hosts | Duration |
+--------------------------------------+-------------+--------+------------+----------------------------------------------------------------------------------------------------+-------------------+-------------+
| 9dfad524-b01a-403e-8e66-73ad3994159e | no-op | PASSED | all | ceph-0, ceph-1, ceph-2, compute-0, compute-1, controller-0, controller-1, controller-2, undercloud | | 0:00:00.231 |
+--------------------------------------+-------------+--------+------------+----------------------------------------------------------------------------------------------------+-------------------+-------------+

Tags: validations
Changed in tripleo:
milestone: wallaby-2 → wallaby-3
Changed in tripleo:
milestone: wallaby-3 → wallaby-rc1
Changed in tripleo:
milestone: wallaby-rc1 → xena-1
Changed in tripleo:
milestone: xena-1 → xena-2
Revision history for this message
Jiri Podivin (jpodivin) wrote :

CLI refactoring fixed this issue for the VF.
As such it is no longer relevant.

https://review.opendev.org/c/openstack/validations-libs/+/782574

Changed in tripleo:
status: Triaged → Fix Released
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.