aboutsummaryrefslogtreecommitdiffstats
path: root/contrib
diff options
context:
space:
mode:
authorYuri Bushmelev <jay4mail@gmail.com>2011-03-17 01:54:39 +0300
committerYuri Bushmelev <jay4mail@gmail.com>2011-03-17 01:54:39 +0300
commitb93654c74e9af2c4fb9d764ffe0f1de8658403cc (patch)
treec01cf439c806a4cfefa9b5220dede7961ef294eb /contrib
parent9eb3023f40ef9520cd60db1b41d2b169993b94b8 (diff)
downloadopenembedded-b93654c74e9af2c4fb9d764ffe0f1de8658403cc.tar.gz
contrib/testing/testbuilder: Update to 0.6.1
Diffstat (limited to 'contrib')
-rwxr-xr-xcontrib/testing/testbuilder/testbuilder14
-rw-r--r--contrib/testing/testbuilder/testbuilder.conf.sample11
2 files changed, 21 insertions, 4 deletions
diff --git a/contrib/testing/testbuilder/testbuilder b/contrib/testing/testbuilder/testbuilder
index 5d9e023ed5..348d81195f 100755
--- a/contrib/testing/testbuilder/testbuilder
+++ b/contrib/testing/testbuilder/testbuilder
@@ -12,7 +12,7 @@
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
-VERSION="0.6"
+VERSION="0.6.1"
PACKAGE="TestBuilder"
TB_DIR=`dirname $0`
@@ -210,7 +210,7 @@ tb_build_images() {
touch "${_log}"
_stime=$(date +%s)
- ${BB_CMD} ${BB_OPTS} ${_images} 2>&1 | tee "${_log}"
+ eval ${BB_CMD} ${BB_OPTS} ${_images} 2>&1 | tee "${_log}"
_rc=$?
_btime=$( TZ=UTC0 date -d "now - $_stime seconds" '+%T' )
@@ -274,7 +274,7 @@ tb_build_machines() {
### Main code
# Parse stages
-unset DO_RUN_BUILDS DO_UPDATE_OE DO_UPDATE_BB
+unset DO_RUN_BUILDS DO_UPDATE_OE DO_UPDATE_BB DO_UPLOAD_LOGS
for stage in $STAGES; do
[ "${stage}" != "${stage#!}" ] && continue
case ${stage} in
@@ -284,6 +284,8 @@ for stage in $STAGES; do
DO_UPDATE_OE=y;;
'update_bb')
DO_UPDATE_BB=y;;
+ 'upload_logs')
+ DO_UPLOAD_LOGS=y;;
*)
tb_log "Unknown stage ${stage}.";;
esac
@@ -500,6 +502,12 @@ for buildconf in ${BUILDS}; do (
done #DISTROS
) done #BUILDS
+# Upload logs
+if [ -n "$DO_UPLOAD_LOGS" ]; then
+ tb_log "Uploading logs to ${UPLOAD_DESTDIR}"
+ eval ${UPLOAD_CMD} ${UPLOAD_OPTS} "${LOG_DIR}/*" "${UPLOAD_DESTDIR}"
+fi
+
tb_log "All done."
exit 0
diff --git a/contrib/testing/testbuilder/testbuilder.conf.sample b/contrib/testing/testbuilder/testbuilder.conf.sample
index 17dc08cf6f..b588407291 100644
--- a/contrib/testing/testbuilder/testbuilder.conf.sample
+++ b/contrib/testing/testbuilder/testbuilder.conf.sample
@@ -12,7 +12,8 @@
# update_bb - update bitbake git tree
# update_oe - update OE git tree
# run_builds - run builds
-STAGES="update_bb update_oe !run_builds"
+# upload_logs - upload logs to some other place
+STAGES="update_bb update_oe !run_builds !upload_logs"
## ACCOUNTING: account some useful things
# df - log free disk space
@@ -57,6 +58,14 @@ MW_USER=""
# Build host machine
# HOST_MACHINE="<cpu model, cores @freq> /<RAM amount>"
+## UPLOAD
+# Upload command
+UPLOAD_CMD="rsync"
+# Upload options
+UPLOAD_OPTS="-av --delete"
+# Upload destination
+UPLOAD_DESTDIR="${TB_BUILDER}@server:/var/www/htdocs/testbuilder/logs"
+
# Misc dirs
TB_BASE=`pwd`
BB_DIR="${TB_BASE}/bitbake"