StarlingX Installation/Update/Patching/Backup/Restore
Go to file
Heitor Matsui 771bddb266 Create wrapper class to run commands via subprocess
This commit creates a class to wrap the main subprocess
commands used by USM, that are 'run', 'check_output' and
'check_call' so that their returned information is logged
into a json file. The purpose of this file is to enable
each deployment history to be recovered in an easier way
on the future.

The json files are stored inside directories named under
the corresponding release, and have a file named under the
deployment stage in which the object was instantiated, e.g.:

/opt/software/summary/starlingx_24.03.0/deploy_precheck.json

These files can grow incrementally in case multiple commands
are executed under the same deployment stage.

The wrapper functions have the same name as the ones from
the 'subprocess' library and behave exactly the same way.

The subprocess functions used on the code currenly will be
replaced by a follow-up commit.

Test Plan
PASS: manually replace subprocess functions on USM code, run
      the respective commands and verify:
      - Command is executed successfully
      - Output and behavior is maintained
      - The json file is created with the expected directory,
        filename and content

Story: 2010676
Task: 48955

Change-Id: Iccf1aef1b0cc064399163eeb58c23fa065a6dab5
Signed-off-by: Heitor Matsui <heitorvieira.matsui@windriver.com>
2023-10-19 09:54:51 -03:00
api-ref/source Switch to newer openstackdocstheme and reno versions 2020-06-04 14:40:40 +02:00
apt-ostree/debian Update sha256sum and md5sum 2023-10-11 15:03:42 +00:00
cgcs-patch Update tox.ini to work with tox 4 2022-12-23 16:01:02 +00:00
devstack Subdirectories 'tsconfig ' relocated to repo 'stx-config' 2019-09-05 13:04:59 -04:00
doc Fix: openstack-tox-docs job is broken with Sphinx >= 5.0.0 2023-08-31 17:01:12 +00:00
enable-dev-patch Update debian package versions to use git commits 2023-02-09 17:26:41 +00:00
extras/scripts Add setup_patch_repo.sh for patch-iso 2020-02-12 14:38:01 -05:00
patch-alarm Update patch-alarm tox for python3 2023-04-12 18:28:07 +00:00
patch-boot-args StarlingX open source release updates 2018-05-31 07:37:12 -07:00
patch-scripts Support dockerd in-service patching with EXAMPLE_DOCKER script 2022-11-27 18:51:12 +00:00
releasenotes Switch to newer openstackdocstheme and reno versions 2020-06-04 14:40:40 +02:00
software Create wrapper class to run commands via subprocess 2023-10-19 09:54:51 -03:00
software-client Build Software Client python wheels package 2023-10-05 20:16:14 +00:00
sw-patch Fix system raising alarm due to outdated file in memory 2023-09-29 09:25:48 -03:00
.gitignore Adding unit tests to tsconfig and clean it up a bit 2019-03-04 19:16:05 +00:00
.gitreview OpenDev Migration Patch 2019-04-19 19:52:36 +00:00
.zuul.yaml Merge "Update patch-alarm tox for python3" 2023-05-02 14:36:06 +00:00
CONTRIBUTORS.wrs StarlingX open source release updates 2018-05-31 07:37:12 -07:00
LICENSE StarlingX open source release updates 2018-05-31 07:37:12 -07:00
README.rst StarlingX open source release updates 2018-05-31 07:37:12 -07:00
bindep.txt Software deploy host implementation 2023-05-08 17:11:53 +00:00
centos_build_layer.cfg Build layering, add layer build config file 2019-10-15 12:56:44 +08:00
centos_dev_wheels.inc Config file changes to remove 'tsconfig ' after relocation to 'stx-config' 2019-09-04 15:36:52 -04:00
centos_iso_image.inc Config file changes to remove 'tsconfig ' after relocation to 'stx-config' 2019-09-04 15:36:52 -04:00
centos_pkg_dirs Support dockerd in-service patching with EXAMPLE_DOCKER script 2022-11-27 18:51:12 +00:00
centos_stable_wheels.inc Config file changes to remove 'tsconfig ' after relocation to 'stx-config' 2019-09-04 15:36:52 -04:00
debian_build_layer.cfg Add debian_build_layer.cfg file 2021-10-05 14:12:40 -04:00
debian_iso_image.inc Merge "Add apt-ostree Debian package" 2023-10-10 15:36:45 +00:00
debian_pkg_dirs Merge "Add apt-ostree Debian package" 2023-10-10 15:36:45 +00:00
debian_stable_wheels.inc Upload skeleton for unified software management 2023-04-03 14:03:04 +00:00
pylint.rc Enable Unused Variable 2019-07-19 10:28:00 -04:00
requirements.txt Add Zuul test foundation 2018-07-25 08:48:07 -05:00
test-requirements.txt Adding rpm-python to bindep to fix pylint 2021-12-15 09:13:13 -06:00
tox.ini Update tox.ini to work with tox 4 2022-12-23 16:01:02 +00:00

README.rst

stx-update

StarlingX Software Management