diff options
author | MatthewLi <matthew.lijun@huawei.com> | 2017-04-10 23:15:39 -0400 |
---|---|---|
committer | MatthewLi <matthew.lijun@huawei.com> | 2017-04-10 23:24:53 -0400 |
commit | a7b6447955d16ef73189d31ed8fb7442f11091be (patch) | |
tree | 7c1a76d5c9269acc4e0ce00bc8fed5f5b164385f /dovetail/container.py | |
parent | 002d7cb256e4f0753f4b738d7f3d2a7872704314 (diff) |
refstack: add manually method to let user can set its tempest.conf and defcore.txt
JIRA: DOVETAIL-394
for refstack, userguide is listed in https://gerrit.opnfv.org/gerrit/#/c/33049/
in CI, use the automate way to generate tempest.conf to let refstack run against SUT, i.e., defcore.tc001.yml
will provide a way to let user can let refstack run against SUT manually, i.e. defcore.tc002.yml
since the tempest.conf autometely generated may not satisfied with SUT, users can adjust its tempest.conf to let the defcore testcases pass.
Change-Id: I5ed212c9c6d864d352d1c497ea039cc553461158
Signed-off-by: MatthewLi <matthew.lijun@huawei.com>
Diffstat (limited to 'dovetail/container.py')
-rw-r--r-- | dovetail/container.py | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/dovetail/container.py b/dovetail/container.py index 4dd3b8f3..f7912d58 100644 --- a/dovetail/container.py +++ b/dovetail/container.py @@ -123,10 +123,18 @@ class Container(object): if not config: return None + # for refstack, support user self_defined configuration + config_volume = "" + if type.lower() == "functest": + config_volume = \ + ' -v %s:%s ' % (dovetail_config['userconfig_dir'], + dovetail_config["functest"]['config']['dir']) + result_volume = ' -v %s:%s ' % (dovetail_config['result_dir'], dovetail_config[type]['result']['dir']) - cmd = 'sudo docker run %s %s %s %s %s %s %s /bin/bash' % \ - (opts, envs, config, sshkey, openrc, result_volume, docker_image) + cmd = 'sudo docker run %s %s %s %s %s %s %s %s /bin/bash' % \ + (opts, envs, config, sshkey, openrc, config_volume, + result_volume, docker_image) dt_utils.exec_cmd(cmd, cls.logger) ret, container_id = \ dt_utils.exec_cmd("sudo docker ps | grep " + docker_image + |