Scripts to allow Jenkins to run the SNAPS-OO tests.
[snaps.git] / ci / run_tests.sh
1 #!/usr/bin/env bash
2
3 set -e
4
5 # Setup Python runtime
6 sudo pip install virtualenv
7 virtualenv ./vpy
8 source ./vpy/bin/activate
9 pip install -e ../
10
11 # $1 is the IP to the pod's build server
12 # $2 is the IP to the pod's control server
13
14 # This operation installs squid on the pod's build server
15 ansible-playbook -i ${1}, setup_proxy.yaml
16
17 # Get RC file from control server
18 filename=$(ssh -o StrictHostKeyChecking=no root@${2} find /var/lib/lxc/controller00_nova_api_placement_container-* -name openrc)
19 scp root@${2}:${filename} .
20
21 # Execute tests
22 python ../snaps/test_runner.py -e openrc -n public -ci -p ${1}:3128
23
24 # Cleanup virtual python runtime
25 rm -rf ./vpy