aboutsummaryrefslogtreecommitdiffstats
path: root/baro_tests/local_agent.py
diff options
context:
space:
mode:
authorToshiaki Takahashi <takahashi.tsc@ncos.nec.co.jp>2018-12-10 07:48:04 +0000
committerToshiaki Takahashi <takahashi.tsc@ncos.nec.co.jp>2018-12-25 06:15:00 +0000
commitff4536dcffc60330c0c483506c1f1ddac626f75c (patch)
treeb19bbabbca0038f44f84417388d8b487ddce2d81 /baro_tests/local_agent.py
parentd6abf61815b5a98ea982f882c1a0f06ca56c5f25 (diff)
Fix anteater issues of baro_tests
* Use yaml.safe_load instead of yaml.load * Not use curl (Use the file prepared by the procedure in the Functest Installation Guide) * Not use /tmp directoriy for security reasen * Add copyright to fix "Licence header missing" Change-Id: Ib4ad56e6a79d7f7d00058d5bd7c6690b8c360753 Signed-off-by: Toshiaki Takahashi <takahashi.tsc@ncos.nec.co.jp>
Diffstat (limited to 'baro_tests/local_agent.py')
-rw-r--r--baro_tests/local_agent.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/baro_tests/local_agent.py b/baro_tests/local_agent.py
index 8201dee0..1a50d963 100644
--- a/baro_tests/local_agent.py
+++ b/baro_tests/local_agent.py
@@ -1,5 +1,7 @@
# -*- coding: utf-8 -*-
-
+#
+# Copyright 2018 OPNFV
+#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
@@ -24,6 +26,8 @@ import tests
logger = None
+TEMP_DIR = '/root'
+
class LocalAgentClient(object):
"""Client to request LocalAgent"""
@@ -201,7 +205,7 @@ def local_agent_main(bt_logger, conf, computes):
if agent_server_running:
test_name = 'barotest'
- tmpfile = '/tmp/' + test_name + '.conf'
+ tmpfile = TEMP_DIR + '/' + test_name + '.conf'
agent_config = conf.get_localagent_config(compute_node)
listen_ip = compute_node.get_ip()