summaryrefslogtreecommitdiffstats
path: root/utils/infra_setup/heat_template/vstf_heat_template/vstf_test.sh
diff options
context:
space:
mode:
authorYiting.Li <liyiting@huawei.com>2016-01-11 16:52:58 +0800
committerJun Li <matthew.lijun@huawei.com>2016-01-12 03:23:20 +0000
commit7180f36f9cac2dadeca49d46b36b23e9fb17b7cb (patch)
tree09c908ce3a2f3989962276ad108730f3b64dd499 /utils/infra_setup/heat_template/vstf_heat_template/vstf_test.sh
parent5c1eeb057a6a954556f14cb4968dfeb2e49e5b64 (diff)
Add ci scripts for vstf tu cases.
JIRA: BOTTLENECK-29 Change-Id: I578273a6130b2eaf67a8bbbea2d3c70bbe66bf90 Signed-off-by: Yiting.Li <liyiting@huawei.com> (cherry picked from commit e899fe06280752d5b51fac6dbb3be8f3d1461a76)
Diffstat (limited to 'utils/infra_setup/heat_template/vstf_heat_template/vstf_test.sh')
-rw-r--r--utils/infra_setup/heat_template/vstf_heat_template/vstf_test.sh18
1 files changed, 13 insertions, 5 deletions
diff --git a/utils/infra_setup/heat_template/vstf_heat_template/vstf_test.sh b/utils/infra_setup/heat_template/vstf_heat_template/vstf_test.sh
index 5f5aa36f..051f2858 100644
--- a/utils/infra_setup/heat_template/vstf_heat_template/vstf_test.sh
+++ b/utils/infra_setup/heat_template/vstf_heat_template/vstf_test.sh
@@ -33,9 +33,11 @@ function fn_vstf_test_config(){
echo "tester_testing_ip = ${tester_testing_ip}"
echo "target_testing_ip = ${target_testing_ip}"
#setting testting ipaddress
- local cmd='vstfadm settings ${tester_testing_ip} ${target_testing_ip}'
+ local cmd="vstfadm settings ${tester_testing_ip} ${target_testing_ip}"
echo "$cmd"
#run_cmd ${manager_control_public_ip} ${VM_MANAGER_USER} ${VM_MANAGER_PASSWD} "${cmd}"
+ ssh-keygen -f "/home/jenkins-ci/.ssh/known_hosts" -R ${manager_control_public_ip}
+ sshpass -p root ssh -o StrictHostKeyChecking=no root@${manager_control_public_ip} "${cmd}"
return 0
}
@@ -51,7 +53,11 @@ function fn_testing_scenario(){
do
local cmd="${head_cmd} ${scene} ${test_tool} ${protocol} ${test_type} \"${test_length_list}\" > /root/${scene}-result.txt"
echo ${cmd}
- run_cmd ${manager_control_public_ip} ${VM_MANAGER_USER} ${VM_MANAGER_PASSWD} "${head_cmd} ${scene} ${test_tool} ${protocol} ${test_type} \"${test_length_list}\" > /root/${scene}"
+
+ ssh-keygen -f "/home/jenkins-ci/.ssh/known_hosts" -R ${manager_control_public_ip}
+ #run_cmd ${manager_control_public_ip} ${VM_MANAGER_USER} ${VM_MANAGER_PASSWD} "${head_cmd} ${scene} ${test_tool} ${protocol} ${test_type} \"${test_length_list}\" > /root/${scene}"
+ sshpass -p root ssh -o StrictHostKeyChecking=no root@${manager_control_public_ip} "${cmd}"
+ sleep 10
done
return 0
}
@@ -62,7 +68,9 @@ function fn_result(){
rm -rf ./result/*
for scene in ${test_scenario_list}
do
- remote_scp_cmd ${manager_control_public_ip} ${VM_MANAGER_USER} ${VM_MANAGER_PASSWD} "/root/${scene}-result.txt" "./result/${scene}" "file"
+ #remote_scp_cmd ${manager_control_public_ip} ${VM_MANAGER_USER} ${VM_MANAGER_PASSWD} "/root/${scene}-result.txt" "./result/${scene}" "file"
+ sshpass -p root ssh -o StrictHostKeyChecking=no root@${manager_control_public_ip} "cat /root/${scene}-result.txt"
+ sshpass -p root scp -o StrictHostKeyChecking=no root@${manager_control_public_ip}:/root/${scene}-result.txt "./result/${scene}"
done
return 0
}
@@ -70,8 +78,8 @@ function fn_result(){
function main(){
fn_parser_ipaddress
fn_vstf_test_config
- #fn_testing_scenario
- #fn_result
+ fn_testing_scenario
+ fn_result
return 0
}