Update openrc files after overcloud service upgrade
We could end up with openrc files not matching the latest templates after an upgrade. Change-Id: I2dbaed7d698b630b1c79cf72fa338e29148dd6e7
This commit is contained in:
parent
222cd5fdde
commit
a633536bfa
@ -1370,6 +1370,7 @@ class OvercloudServiceUpgrade(KollaAnsibleMixin, KayobeAnsibleMixin,
|
|||||||
deployment.
|
deployment.
|
||||||
* Perform a kolla-ansible upgrade of the overcloud services.
|
* Perform a kolla-ansible upgrade of the overcloud services.
|
||||||
* Configure and upgrade kayobe extra services.
|
* Configure and upgrade kayobe extra services.
|
||||||
|
* Regenerate openrc files for the admin user.
|
||||||
|
|
||||||
This can be used in conjunction with the --tags and --kolla-tags arguments
|
This can be used in conjunction with the --tags and --kolla-tags arguments
|
||||||
to upgrade specific services.
|
to upgrade specific services.
|
||||||
@ -1401,6 +1402,13 @@ class OvercloudServiceUpgrade(KollaAnsibleMixin, KayobeAnsibleMixin,
|
|||||||
self.run_kayobe_playbooks(parsed_args, playbooks,
|
self.run_kayobe_playbooks(parsed_args, playbooks,
|
||||||
extra_vars=extra_vars, limit="overcloud")
|
extra_vars=extra_vars, limit="overcloud")
|
||||||
|
|
||||||
|
# Post-deployment configuration.
|
||||||
|
self.run_kolla_ansible_overcloud(parsed_args, "post-deploy")
|
||||||
|
# Create an environment file for accessing the public API as the admin
|
||||||
|
# user.
|
||||||
|
playbooks = _build_playbook_list("public-openrc")
|
||||||
|
self.run_kayobe_playbooks(parsed_args, playbooks, ignore_limit=True)
|
||||||
|
|
||||||
|
|
||||||
class OvercloudServiceDestroy(KollaAnsibleMixin, KayobeAnsibleMixin,
|
class OvercloudServiceDestroy(KollaAnsibleMixin, KayobeAnsibleMixin,
|
||||||
VaultMixin, Command):
|
VaultMixin, Command):
|
||||||
|
@ -1553,6 +1553,14 @@ class TestCase(unittest.TestCase):
|
|||||||
"kayobe_action": "upgrade",
|
"kayobe_action": "upgrade",
|
||||||
}
|
}
|
||||||
),
|
),
|
||||||
|
mock.call(
|
||||||
|
mock.ANY,
|
||||||
|
[
|
||||||
|
utils.get_data_files_path("ansible",
|
||||||
|
"public-openrc.yml"),
|
||||||
|
],
|
||||||
|
ignore_limit=True,
|
||||||
|
),
|
||||||
]
|
]
|
||||||
self.assertEqual(expected_calls, mock_run.call_args_list)
|
self.assertEqual(expected_calls, mock_run.call_args_list)
|
||||||
|
|
||||||
@ -1565,6 +1573,10 @@ class TestCase(unittest.TestCase):
|
|||||||
mock.ANY,
|
mock.ANY,
|
||||||
"upgrade"
|
"upgrade"
|
||||||
),
|
),
|
||||||
|
mock.call(
|
||||||
|
mock.ANY,
|
||||||
|
"post-deploy"
|
||||||
|
),
|
||||||
]
|
]
|
||||||
self.assertEqual(expected_calls, mock_kolla_run.call_args_list)
|
self.assertEqual(expected_calls, mock_kolla_run.call_args_list)
|
||||||
|
|
||||||
|
5
releasenotes/notes/openrc-upgrade-9e14888d600f6839.yaml
Normal file
5
releasenotes/notes/openrc-upgrade-9e14888d600f6839.yaml
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
---
|
||||||
|
fixes:
|
||||||
|
- |
|
||||||
|
Kayobe now updates ``openrc`` files when using the ``kayobe overcloud service
|
||||||
|
upgrade`` command.
|
Loading…
Reference in New Issue
Block a user