summaryrefslogtreecommitdiffstats
path: root/jjb/cperf/cperf-ci-jobs.yml
diff options
context:
space:
mode:
authorJamo Luhrsen <jluhrsen@redhat.com>2017-03-01 22:49:45 -0800
committerJamo Luhrsen <jluhrsen@redhat.com>2017-03-10 11:03:11 -0800
commit999eea7487d1d17d83115fcfae44bb835b9f6360 (patch)
tree1f2a445bfd58a199324f364bffa203d87518ac8d /jjb/cperf/cperf-ci-jobs.yml
parent47dab344fe4a76b92a81529117d6a2248e3df0bc (diff)
Add logic to allow ODL Cbench suite to run from docker container
- also changing deploy scenario to only use a single controller Change-Id: Ic1aa9489b17478865db7f9509091e165fbe4a6b3 Signed-off-by: Jamo Luhrsen <jluhrsen@redhat.com>
Diffstat (limited to 'jjb/cperf/cperf-ci-jobs.yml')
-rw-r--r--jjb/cperf/cperf-ci-jobs.yml40
1 files changed, 35 insertions, 5 deletions
diff --git a/jjb/cperf/cperf-ci-jobs.yml b/jjb/cperf/cperf-ci-jobs.yml
index 125937e80..d1914f6f1 100644
--- a/jjb/cperf/cperf-ci-jobs.yml
+++ b/jjb/cperf/cperf-ci-jobs.yml
@@ -113,13 +113,43 @@
builders:
- shell: |
#!/bin/bash
- set +e
- # TODO: need to figure out the logic to get ${CONTROLLER_IP} used below
+ set -o errexit
+ set -o nounset
+ set -o pipefail
+ undercloud_mac=$(sudo virsh domiflist undercloud | grep default | \
+ grep -Eo "[0-9a-f]+:[0-9a-f]+:[0-9a-f]+:[0-9a-f]+:[0-9a-f]+:[0-9a-f]+")
+ INSTALLER_IP=$(/usr/sbin/arp -e | grep ${undercloud_mac} | awk {'print $1'})
+ sudo scp $INSTALLER_IP:/home/stack/stackrc /tmp/stackrc
+ source /tmp/stackrc
+
+ # robot suites need the ssh key to log in to controller nodes, so throwing it
+ # in tmp, and mounting /tmp as $HOME as far as robot is concerned
+ sudo mkdir -p /tmp/.ssh
+ sudo scp $INSTALLER_IP:/home/stack/.ssh/id_rsa /tmp/.ssh/
+ sudo chmod -R 0600 /tmp/.ssh
+
+ # cbench requires the openflow drop test feature to be installed.
+ sshpass -p karaf ssh -o StrictHostKeyChecking=no \
+ -o UserKnownHostsFile=/dev/null \
+ -o LogLevel=error \
+ -p 8101 karaf@$SDN_CONTROLLER_IP \
+ feature:install odl-openflowplugin-flow-services-ui odl-openflowplugin-drop-test
+
docker pull opnfv/cperf:$DOCKER_TAG
- robot_cmd="pybot -e exclude -v ODL_SYSTEM_IP:${CONTROLLER_IP} -v switch_count:100 -v loops:10 \
- -v TOOLS_SYSTEM_IP:localhost -v duration_in_seconds:60"
+
+ robot_cmd="pybot -e exclude -L TRACE \
+ -v ODL_SYSTEM_1_IP:${SDN_CONTROLLER_IP} \
+ -v ODL_SYSTEM_IP:${SDN_CONTROLLER_IP} \
+ -v BUNDLEFOLDER:/opt/opendaylight \
+ -v RESTCONFPORT:8081 \
+ -v USER_HOME:/tmp \
+ -v USER:heat-admin \
+ -v ODL_SYSTEM_USER:heat-admin \
+ -v TOOLS_SYSTEM_IP:localhost \
+ -v of_port:6653"
robot_suite="/home/opnfv/repos/odl_test/csit/suites/openflowplugin/Performance/010_Cbench.robot"
- docker run opnfv/cperf:$DOCKER_TAG ${robot_cmd} ${robot_suite}
+
+ docker run -v /tmp:/tmp opnfv/cperf:$DOCKER_TAG ${robot_cmd} ${robot_suite}
- builder:
name: cperf-cleanup