From 44cbd875b1f5b0b7950b4f6865b2ca01881532d0 Mon Sep 17 00:00:00 2001 From: Linda Wang Date: Fri, 15 Dec 2017 02:57:26 +0000 Subject: Inject all envs in openrc into CONST After "env_prepare" is removed, some specific vars in openrc (eg,."EXTERNAL_NETWORK") loaded to os.environ should be injected into CONST in one python process. Conflicts: functest/ci/run_tests.py Change-Id: Iaa5c6047033dc2a30c533174e2016111759aec31 Signed-off-by: Linda Wang (cherry picked from commit 6a2ee8883daf1795ec84fc2868c17c0723025447) --- functest/utils/openstack_utils.py | 1 + 1 file changed, 1 insertion(+) (limited to 'functest/utils') diff --git a/functest/utils/openstack_utils.py b/functest/utils/openstack_utils.py index d8b1cf6f9..8a4ce2e36 100644 --- a/functest/utils/openstack_utils.py +++ b/functest/utils/openstack_utils.py @@ -127,6 +127,7 @@ def source_credentials(rc_file): key = re.sub(r'^["\' ]*|[ \'"]*$', '', var[0]) value = re.sub(r'^["\' ]*|[ \'"]*$', '', "".join(var[1:])) os.environ[key] = value + CONST.__setattr__(key, value) def get_credentials_for_rally(): -- cgit 1.2.3-korg