the one script to fire it all off
authorJason Etheridge <jason@esilibrary.com>
Thu, 3 Oct 2013 15:10:56 +0000 (11:10 -0400)
committerJason Etheridge <jason@esilibrary.com>
Thu, 3 Oct 2013 15:10:56 +0000 (11:10 -0400)
qa/test.sh [new file with mode: 0755]

diff --git a/qa/test.sh b/qa/test.sh
new file mode 100755 (executable)
index 0000000..19cf2d7
--- /dev/null
@@ -0,0 +1,22 @@
+#!/bin/bash
+export TARGET_USER=evergreen
+export TARGET_HOST=192.168.71.51
+export TARGET_PATH=/home/evergreen/
+export LOCAL_QA_GIT_PATH=/home/opensrf/git/random/
+export LOCAL_QA_BRANCH=collab/phasefx/wheezy_installer
+export LOCAL_HTML_PATH=/home/opensrf/public_html/
+cd ${LOCAL_QA_GIT_PATH} || exit -1
+git checkout ${LOCAL_QA_BRANCH} || exit -1
+git fetch --all || exit -1
+git pull || exit -1
+scp installer/wheezy/installer_installer.sh ${TARGET_USER}@${TARGET_HOST}:${TARGET_PATH} || exit -1
+cd ${LOCAL_HTML_PATH} || exit -1
+export ARCHIVE_DIR=`date +%F_%T` || exit -1
+mkdir -p archive/${ARCHIVE_DIR} || exit -1
+mv *.* archive/${ARCHIVE_DIR} || exit -1
+cp archive/${ARCHIVE_DIR}/*.hash . || exit -1
+cp ${LOCAL_QA_GIT_PATH}qa/test_output.css .
+echo '<html><head></head><body><h1>Testing in progress</h1><a href="archive/">previous runs</a></body></html>' > test.html
+ln -s test.html index.html
+ssh ${TARGET_USER}@${TARGET_HOST} ${TARGET_PATH}installer_installer.sh 2>&1 | tee output.txt
+${LOCAL_QA_GIT_PATH}qa/test_output_webifier.pl output.txt