aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVincenzo Riccobene <vincenzox.m.riccobene@intel.com>2016-01-05 16:53:43 +0000
committerJörgen Karlsson <jorgen.w.karlsson@ericsson.com>2016-01-06 22:25:34 +0000
commitffdd523055d2395d1216c5fa0007ed6af0b6146e (patch)
treedf4886ee5845b17e54c794ef8260b84c4aa3d191
parent2f76296ddd88451361f2b47035afdafb3130f47e (diff)
Fix ApexLake setup
Changes the directories where to store apexlake data in order to allow a non super user to run the setup. JIRA: YARDSTICK-35 Change-Id: I871b2ab793183887c86666bfe2241e3c26b4f427 Signed-off-by: Vincenzo Riccobene <vincenzox.m.riccobene@intel.com>
-rw-r--r--yardstick/vTC/apexlake/experimental_framework/common.py12
-rw-r--r--yardstick/vTC/apexlake/setup.py6
-rw-r--r--yardstick/vTC/apexlake/tests/common_test.py2
3 files changed, 10 insertions, 10 deletions
diff --git a/yardstick/vTC/apexlake/experimental_framework/common.py b/yardstick/vTC/apexlake/experimental_framework/common.py
index 6b5f932ce..afe70241a 100644
--- a/yardstick/vTC/apexlake/experimental_framework/common.py
+++ b/yardstick/vTC/apexlake/experimental_framework/common.py
@@ -76,10 +76,10 @@ def init_conf_file(api=False):
global CONF_FILE
if api:
CONF_FILE = ConfigurationFile(cf.get_sections_api(),
- '/etc/apexlake/apexlake.conf')
+ '/tmp/apexlake/apexlake.conf')
else:
CONF_FILE = ConfigurationFile(cf.get_sections(),
- '/etc/apexlake/apexlake.conf')
+ '/tmp/apexlake/apexlake.conf')
def init_general_vars(api=False):
@@ -99,10 +99,10 @@ def init_general_vars(api=False):
"is not present in configuration file")
TEMPLATE_DIR = '/tmp/apexlake/heat_templates/'
- if not os.path.exists(TEMPLATE_DIR):
- os.makedirs(TEMPLATE_DIR)
- cmd = "cp /etc/apexlake/heat_templates/*.yaml {}".format(TEMPLATE_DIR)
- run_command(cmd)
+ # if not os.path.exists(TEMPLATE_DIR):
+ # os.makedirs(TEMPLATE_DIR)
+ # cmd = "cp /tmp/apexlake/heat_templates/*.yaml {}".format(TEMPLATE_DIR)
+ # run_command(cmd)
if not api:
# Validate template name
diff --git a/yardstick/vTC/apexlake/setup.py b/yardstick/vTC/apexlake/setup.py
index e33b5bfc8..8ab3f4845 100644
--- a/yardstick/vTC/apexlake/setup.py
+++ b/yardstick/vTC/apexlake/setup.py
@@ -30,9 +30,9 @@ setup(name='apexlake',
]
},
data_files=[
- ('/etc/apexlake/', ['apexlake.conf']),
- ('/etc/apexlake/heat_templates/',
+ ('/tmp/apexlake/', ['apexlake.conf']),
+ ('/tmp/apexlake/heat_templates/',
['heat_templates/vTC.yaml']),
- ('/etc/apexlake/heat_templates/',
+ ('/tmp/apexlake/heat_templates/',
['heat_templates/stress_workload.yaml'])
])
diff --git a/yardstick/vTC/apexlake/tests/common_test.py b/yardstick/vTC/apexlake/tests/common_test.py
index 2ce6f7717..293754b16 100644
--- a/yardstick/vTC/apexlake/tests/common_test.py
+++ b/yardstick/vTC/apexlake/tests/common_test.py
@@ -137,7 +137,7 @@ class TestCommonInit(unittest.TestCase):
self.assertEqual(common.TEMPLATE_NAME, 'vTC.yaml')
self.assertEqual(common.RESULT_DIR, '/tmp/apexlake/results/')
self.assertEqual(common.ITERATIONS, 1)
- mock_makedirs.assert_called_once_with('/tmp/apexlake/heat_templates/')
+ # mock_makedirs.assert_called_once_with('/tmp/apexlake/heat_templates/')
class TestCommonInit2(unittest.TestCase):