summaryrefslogtreecommitdiffstats
path: root/ci/daily.sh
diff options
context:
space:
mode:
authormbeierl <mark.beierl@dell.com>2017-01-17 14:22:18 -0500
committermbeierl <mark.beierl@dell.com>2017-01-18 13:58:14 -0500
commit6ce8e3db303e3a32c2a57e0638c1de070a49ef06 (patch)
treec0775706ee17ff6616cfbc5649644125039c0fd5 /ci/daily.sh
parentc3eff480168e4dca242654374c31857dfb577141 (diff)
StorPerf Daily Job
Helper script that determines what installer was used. Script to generate RC file for container. Script to determine number of Cinder nodes. Daily job to pull new container, create stack based on number of Cinder nodes, issue a warm up, and then run a series of performance tests against the stack. Deletes stack once complete. JIRA: STORPERF-87 Signed-off-by: mbeierl <mark.beierl@dell.com> Change-Id: I551f21ffc85f11b0c0724205e952551022a94f5b
Diffstat (limited to 'ci/daily.sh')
-rwxr-xr-xci/daily.sh42
1 files changed, 29 insertions, 13 deletions
diff --git a/ci/daily.sh b/ci/daily.sh
index bdfe746..9ee6afb 100755
--- a/ci/daily.sh
+++ b/ci/daily.sh
@@ -14,6 +14,21 @@ then
WORKSPACE=`pwd`
fi
+if [ -d $WORKSPACE/ci/job ]
+then
+ sudo rm -rf $WORKSPACE/ci/job
+fi
+
+virtualenv $WORKSPACE/ci/job/storperf_daily_venv
+source $WORKSPACE/ci/job/storperf_daily_venv/bin/activate
+
+pip install --upgrade setuptools
+pip install functools32
+pip install pytz
+pip install osc_lib
+pip install python-openstackclient
+pip install python-heatclient
+
# This is set by Jenkins, but if we are running manually, just use the
# current hostname.
if [ -z "$NODE_NAME" ]
@@ -22,12 +37,10 @@ then
fi
export POD_NAME=$NODE_NAME
-if [ -d $WORKSPACE/ci/job ]
-then
- sudo rm -rf $WORKSPACE/ci/job
-fi
sudo find $WORKSPACE/ -name '*.db' -exec rm -fv {} \;
+export INSTALLER=`./detect_installer.sh`
+
$WORKSPACE/ci/generate-admin-rc.sh
$WORKSPACE/ci/generate-environment.sh
@@ -38,16 +51,20 @@ do
done
echo "Checking for an existing stack"
-STACK_ID=`heat stack-list | grep StorPerfAgentGroup | awk '{print $2}'`
+STACK_ID=`openstack stack list | grep StorPerfAgentGroup | awk '{print $2}'`
if [ ! -z $STACK_ID ]
then
- heat stack-delete -y StorPerfAgentGroup
+ openstack stack delete --yes --wait StorPerfAgentGroup
fi
-while [ ! -z $STACK_ID ]
-do
- STACK_ID=`heat stack-list | grep StorPerfAgentGroup | awk '{print $2}'`
-done
+echo Checking for Ubuntu 14.04 image in Glance
+IMAGE=`openstack image list | grep "Trusty x86_64"`
+if [ -z $IMAGE ]
+then
+ wget https://cloud-images.ubuntu.com/releases/14.04/release/ubuntu-14.04-server-cloudimg-amd64-disk1.img
+ openstack image create "Trusty x86_64" --disk-format qcow2 --public \
+ --container-format bare --file ubuntu-14.04-server-cloudimg-amd64-disk1.img
+fi
echo "TEST_DB_URL=http://testresults.opnfv.org/test/api/v1" >> $WORKSPACE/ci/job/admin.rc
echo "INSTALLER_TYPE=${INSTALLER}" >> $WORKSPACE/ci/job/admin.rc
@@ -60,11 +77,11 @@ do
done
echo Creating 1:1 stack
-$WORKSPACE/ci/create_stack.sh $CINDER_NODES 10
+$WORKSPACE/ci/create_stack.sh $CINDER_NODES 10 "Trusty x86_64" $NETWORK
export QUEUE_DEPTH=8
export BLOCK_SIZE=16384
-export WORKLOAD=ws
+export WORKLOAD=_warm_up
export SCENARIO_NAME="${CINDER_BACKEND}_${WORKLOAD}"
WARM_UP=`$WORKSPACE/ci/start_job.sh | awk '/job_id/ {print $2}' | sed 's/"//g'`
@@ -77,7 +94,6 @@ do
| awk '/Status/ {print $2}' | sed 's/"//g'`
done
-
for WORKLOAD in ws wr rs rr rw
do
for BLOCK_SIZE in 2048 8192 16384