Handle existing VIM strategies during subcloud rehome
Introduce a check to prevent rehoming subclouds with VIM strategies
in 'abort' phase. Existing management affecting alarm check covers
other ongoing states.
This commit also auto-deletes VIM strategies in 'applied', 'ready-to-
apply', 'build-failed', or 'build-timeout' states after rehoming,
avoiding conflicts during DC orchestration on the new system
controller.
Test Plan:
1. PASS - Attempt to rehome a subcloud with a VIM strategy in the 'abort' phase, verify that it fails;
2. PASS - Rehome a subcloud containing a VIM strategy in a valid state (applied, ready-to-apply, build-failed or build-timeout) and verify that the strategy is automatically deleted;
3. PASS - Rehome a subcloud without existing VIM strategies and verify that it still works as expected;
4. PASS - Create a DC orchestrator strategy, manually delete the VIM strategy in the subcloud and then try to delete the DC orch. strategy; verify that it's deleted successfully.
Reviewed: https:/ /review. opendev. org/c/starlingx /ansible- playbooks/ +/908945 /opendev. org/starlingx/ ansible- playbooks/ commit/ b223c3a2674c7c6 f16860838c06730 d0ba3321b4
Committed: https:/
Submitter: "Zuul (22348)"
Branch: master
commit b223c3a2674c7c6 f16860838c06730 d0ba3321b4
Author: Gustavo Herzmann <email address hidden>
Date: Tue Feb 13 16:15:08 2024 -0300
Handle existing VIM strategies during subcloud rehome
Introduce a check to prevent rehoming subclouds with VIM strategies
in 'abort' phase. Existing management affecting alarm check covers
other ongoing states.
This commit also auto-deletes VIM strategies in 'applied', 'ready-to-
apply', 'build-failed', or 'build-timeout' states after rehoming,
avoiding conflicts during DC orchestration on the new system
controller.
Test Plan:
'abort' phase, verify that it fails;
(applied, ready-to-apply, build-failed or build-timeout) and
verify that the strategy is automatically deleted;
verify that it still works as expected;
strategy in the subcloud and then try to delete the DC orch.
strategy; verify that it's deleted successfully.
1. PASS - Attempt to rehome a subcloud with a VIM strategy in the
2. PASS - Rehome a subcloud containing a VIM strategy in a valid state
3. PASS - Rehome a subcloud without existing VIM strategies and
4. PASS - Create a DC orchestrator strategy, manually delete the VIM
Closes-Bug: 2053065
Change-Id: Ia11d8871423584 5d8e3c274196d6f 809400851ea
Signed-off-by: Gustavo Herzmann <email address hidden>