Bugfix:fix a bug that yardstick_key.pub cannot be found in Yardstick docker 27/23827/3
authorJingLu5 <lvjing5@huawei.com>
Tue, 1 Nov 2016 07:22:02 +0000 (15:22 +0800)
committerJingLu5 <lvjing5@huawei.com>
Tue, 1 Nov 2016 07:39:39 +0000 (15:39 +0800)
JIRA: YARDSTICK-379

Change-Id: I8416a38c94e07f0f83cb74d920a7c4d22a0cd04a
Signed-off-by: JingLu5 <lvjing5@huawei.com>
yardstick/benchmark/contexts/heat.py

index b504cd4..fcbe825 100644 (file)
@@ -18,6 +18,7 @@ from yardstick.benchmark.contexts.model import PlacementGroup
 from yardstick.benchmark.contexts.model import Network
 from yardstick.benchmark.contexts.model import update_scheduler_hints
 from yardstick.orchestrator.heat import HeatTemplate
+from yardstick.definitions import YARDSTICK_ROOT_PATH
 
 
 class HeatContext(Context):
@@ -39,7 +40,8 @@ class HeatContext(Context):
         self._user = None
         self.template_file = None
         self.heat_parameters = None
-        self.key_filename = 'yardstick/resources/files/yardstick_key'
+        self.key_filename = YARDSTICK_ROOT_PATH + \
+            'yardstick/resources/files/yardstick_key'
         super(self.__class__, self).__init__()
 
     def init(self, attrs):