update/software
Luis Eduardo Bonatti cad378bac5 Delete deployment
This commit adds the function to delete a deployment. There's some
validations in order to be able to delete it some of them is:
The deploy host state should be one of: [pending, failed]
The deploy state should be one of: [start-done, start-failed,
abort-done]
All nodes are running from release software.

In case of delete a major release the data generated during the deploy
should also be deleted which include /sysroot/upgrade/ostree_repo,
/sysroot/upgrade/sysroot and the folders [config, fluxcd, helm,
nfv/vim, sysinv, puppet, deploy] under
/opt/platform/<folders>/<sw_version>.

Also delete the /var/lib/postgres/<sw_version>.

Note: The function is not called by any endpoint at this point as the
New USM REST API is in development to avoid conflicts and rework.

Test Plan:
PASS: Fold]ers deleted on /opt/platform/<folders>/<sw_version>
with start-done and start-failed deploy state.
PASS: Cleanup of staging data.
PASS: Failed to attempt deletion with a deployed host N+1 release

Story: 2010676
Task: 49979

Change-Id: I1789172edc730e6c94fa6bec7f5881c0bdfd7eab
Signed-off-by: Luis Eduardo Bonatti <LuizEduardo.Bonatti@windriver.com>
2024-04-26 17:08:02 -03:00
..
debian Raise deploy state out of sync alarm 2024-04-15 19:14:23 +00:00
scripts USM deploy state 2024-04-17 16:40:07 +00:00
service-files Create message class to sync deploy state between controllers 2024-02-16 15:51:49 +00:00
software Delete deployment 2024-04-26 17:08:02 -03:00
.coveragerc Upload skeleton for unified software management 2023-04-03 14:03:04 +00:00
Hacking.rst Upload skeleton for unified software management 2023-04-03 14:03:04 +00:00
LICENSE Upload skeleton for unified software management 2023-04-03 14:03:04 +00:00
README.rst Upload skeleton for unified software management 2023-04-03 14:03:04 +00:00
pylint.rc Add version to software-api and software client 2024-02-08 04:23:29 -05:00
requirements.txt Add version to software-api and software client 2024-02-08 04:23:29 -05:00
setup.cfg deploy state changed update 2024-02-23 13:43:09 +00:00
setup.py Bash completion for USM 2023-08-03 16:21:00 +00:00
test-requirements.txt Upload skeleton for unified software management 2023-04-03 14:03:04 +00:00
tox.ini USM deploy state 2024-04-17 16:40:07 +00:00

README.rst

software

StarlingX Unified Software Delivery and Management