From 00204688f01b8367100c452e58befbcd3fee2014 Mon Sep 17 00:00:00 2001 From: NastyaUrlapova Date: Sat, 5 Sep 2015 11:03:27 +0300 Subject: [PATCH] Changed default directory for certificates Change-Id: Idf1585bbd5ef010874ca354b26055a08d102ecd5 Related-Bug: #1491001 --- fuelweb_test/settings.py | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/fuelweb_test/settings.py b/fuelweb_test/settings.py index 44ff6f379..cec9014de 100644 --- a/fuelweb_test/settings.py +++ b/fuelweb_test/settings.py @@ -31,15 +31,21 @@ ENV_NAME = os.environ.get("ENV_NAME", "fuel_system_test") VIRTUAL_ENV = os.environ.get("VIRTUAL_ENV", "") ISO_PATH = os.environ.get('ISO_PATH') +LOGS_DIR = os.environ.get('LOGS_DIR', os.getcwd()) # cdrom or usb ADMIN_BOOT_DEVICE = os.environ.get('ADMIN_BOOT_DEVICE', 'cdrom') DNS = os.environ.get('DNS', '8.8.8.8') PUBLIC_TEST_IP = os.environ.get('PUBLIC_TEST_IP', '8.8.8.8') DISABLE_SSL = get_var_as_bool('DISABLE_SSL', False) +SSL_CERTS_DIR = os.environ.get('SSL_CERTS_DIR', os.getcwd()) +if not os.path.exists(SSL_CERTS_DIR): + os.makedirs(SSL_CERTS_DIR) USER_OWNED_CERT = get_var_as_bool('USER_OWNED_CERT', True) -PATH_TO_CERT = os.environ.get('PATH_TO_CERT', '/tmp/ca.crt') -PATH_TO_PEM = os.environ.get('PATH_TO_PEM', '/tmp/ca.pem') +PATH_TO_CERT = os.environ.get('PATH_TO_CERT', os.path.join( + SSL_CERTS_DIR, 'ca.crt')) +PATH_TO_PEM = os.environ.get('PATH_TO_PEM', os.path.join( + SSL_CERTS_DIR, 'ca.pem')) OPENSTACK_RELEASE_CENTOS = 'centos' OPENSTACK_RELEASE_UBUNTU = 'ubuntu' @@ -230,7 +236,6 @@ NEUTRON_SEGMENT = { 'tun': 'tun' } -LOGS_DIR = os.environ.get('LOGS_DIR', os.getcwd()) USE_ALL_DISKS = get_var_as_bool('USE_ALL_DISKS', True) UPLOAD_MANIFESTS = get_var_as_bool('UPLOAD_MANIFESTS', False)