Browse Source

Pass undercloud's private key to inventory used in package_update.

As the Ansible playbook is being executed from the mistral_executor
container, we need to establish a conection to the Undercloud via ssh
not local as it was being done up to now. In order to be able to ssh
into the host we need to provide with the tripleo-ansible's user ssh
key.

Depends-On: https://review.opendev.org/#/c/677777/

Closes-Bug: #1832932
Change-Id: I20948d49b3023dc76acff8779bbe182886e55838

(cherry picked from commit 28a3d02061)
tags/11.5.1
Jose Luis Franco Arza 1 month ago
parent
commit
9b9b5aaadc
1 changed files with 2 additions and 0 deletions
  1. 2
    0
      tripleoclient/utils.py

+ 2
- 0
tripleoclient/utils.py View File

@@ -1210,6 +1210,8 @@ def get_tripleo_ansible_inventory(inventory_file=None,
1210 1210
                 '--stack', stack,
1211 1211
                 '--ansible_ssh_user', ssh_user,
1212 1212
                 '--undercloud-connection', 'ssh',
1213
+                '--undercloud-key-file',
1214
+                '/var/lib/mistral/.ssh/tripleo-admin-rsa',
1213 1215
                 '--static-yaml-inventory', inventory_file)
1214 1216
         except processutils.ProcessExecutionError as e:
1215 1217
             message = _("Failed to generate inventory: %s") % str(e)

Loading…
Cancel
Save