Adjust TripleoInventory arguments, don't pass config object

Instead pass the individual named parameters, which is clearer
and easier for tests, particularly now that some of these are
optional.

Change-Id: Ic49cccdcd900e0ca97d1f6c4675e865e6357363d
This commit is contained in:
Steven Hardy 2018-01-03 17:08:39 +00:00
parent cb18c3c30a
commit 3d732165e1
1 changed files with 10 additions and 3 deletions

View File

@ -120,9 +120,16 @@ def main():
configs.auth_token,
configs.cacert)
hclient = heat_client.Client('1', session=session)
inventory = TripleoInventory(configs,
session,
hclient)
inventory = TripleoInventory(
session=session,
hclient=hclient,
auth_url=configs.auth_url,
cacert=configs.cacert,
project_name=configs.project_name,
username=configs.username,
ansible_ssh_user=configs.ansible_ssh_user,
plan_name=configs.plan)
if configs.list or configs.static_inventory:
try:
inventory_list = inventory.list()