From f87088f24875450847dc305e6e7c56db8264bdbc Mon Sep 17 00:00:00 2001 From: Luc Provoost Date: Mon, 16 Jan 2023 16:21:50 +0100 Subject: Fix issue with system_ready_for_rapid file In the /opt/rapid directory, we used to check for the existance of the file system_ready_for_rapid. This file was created when all the initialization is done properly. This check was however broken and always resulted succesfully, even if the file did not exist. When executing runrapid.py, the system will now wait to connect to PROX, till this file exists. The file is created when running start.sh Signed-off-by: Luc Provoost Change-Id: Idca52549aae40070a0b6ea1d7ccbf6c322dc631d --- VNFs/DPPD-PROX/helper-scripts/rapid/prox_ctrl.py | 6 ++++-- VNFs/DPPD-PROX/helper-scripts/rapid/rapid_defaults.py | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) (limited to 'VNFs/DPPD-PROX/helper-scripts/rapid') diff --git a/VNFs/DPPD-PROX/helper-scripts/rapid/prox_ctrl.py b/VNFs/DPPD-PROX/helper-scripts/rapid/prox_ctrl.py index 0288ce94..8754ebc4 100644 --- a/VNFs/DPPD-PROX/helper-scripts/rapid/prox_ctrl.py +++ b/VNFs/DPPD-PROX/helper-scripts/rapid/prox_ctrl.py @@ -47,8 +47,10 @@ class prox_ctrl(object): on %s, attempt: %d" % (self._ip, attempts)) while True: try: - self.run_cmd('test -e /opt/rapid/system_ready_for_rapid') - break + if (self.run_cmd('test -e /opt/rapid/system_ready_for_rapid \ + && echo exists')): + break + time.sleep(2) except RuntimeWarning as ex: RapidLog.debug("RuntimeWarning %d:\n%s" % (ex.returncode, ex.output.strip())) diff --git a/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_defaults.py b/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_defaults.py index 6fe86848..27d2430d 100644 --- a/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_defaults.py +++ b/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_defaults.py @@ -21,7 +21,7 @@ class RapidDefaults(object): Class to define the test defaults """ test_params = { - 'version' : '2023.01.09', # Please do NOT change, used for debugging + 'version' : '2023.01.16', # Please do NOT change, used for debugging 'environment_file' : 'rapid.env', #Default string for environment 'test_file' : 'tests/basicrapid.test', #Default string for test 'machine_map_file' : 'machine.map', #Default string for machine map file -- cgit 1.2.3-korg