summaryrefslogtreecommitdiffstats
path: root/src/ceph/qa/machine_types/schedule_subset.sh
diff options
context:
space:
mode:
authorQiaowei Ren <qiaowei.ren@intel.com>2018-01-04 13:43:33 +0800
committerQiaowei Ren <qiaowei.ren@intel.com>2018-01-05 11:59:39 +0800
commit812ff6ca9fcd3e629e49d4328905f33eee8ca3f5 (patch)
tree04ece7b4da00d9d2f98093774594f4057ae561d4 /src/ceph/qa/machine_types/schedule_subset.sh
parent15280273faafb77777eab341909a3f495cf248d9 (diff)
initial code repo
This patch creates initial code repo. For ceph, luminous stable release will be used for base code, and next changes and optimization for ceph will be added to it. For opensds, currently any changes can be upstreamed into original opensds repo (https://github.com/opensds/opensds), and so stor4nfv will directly clone opensds code to deploy stor4nfv environment. And the scripts for deployment based on ceph and opensds will be put into 'ci' directory. Change-Id: I46a32218884c75dda2936337604ff03c554648e4 Signed-off-by: Qiaowei Ren <qiaowei.ren@intel.com>
Diffstat (limited to 'src/ceph/qa/machine_types/schedule_subset.sh')
-rwxr-xr-xsrc/ceph/qa/machine_types/schedule_subset.sh45
1 files changed, 45 insertions, 0 deletions
diff --git a/src/ceph/qa/machine_types/schedule_subset.sh b/src/ceph/qa/machine_types/schedule_subset.sh
new file mode 100755
index 0000000..c26231a
--- /dev/null
+++ b/src/ceph/qa/machine_types/schedule_subset.sh
@@ -0,0 +1,45 @@
+#!/bin/bash
+
+#command line => CEPH_BRANCH=<branch>; MACHINE_NAME=<machine_type>; SUITE_NAME=<suite>; ../schedule_subset.sh <day_of_week> $CEPH_BRANCH $MACHINE_NAME $SUITE_NAME $CEPH_QA_EMAIL
+
+# $1 - part (day of week)
+# $2 - branch name
+# $3 - machine name
+# $4 - suite name
+# $5 - email address
+# $6 - filter out (this arg is to be at the end of the command line for now)
+
+## example #1
+## (date +%U) week number
+## % 2 - mod 2 (e.g. 0,1,0,1 ...)
+## * 7 - multiplied by 7 (e.g. 0,7,0,7...)
+## $1 day of the week (0-6)
+## /14 for 2 weeks
+
+## example #2
+## (date +%U) week number
+## % 4 - mod 4 (e.g. 0,1,2,3,0,1,2,3 ...)
+## * 7 - multiplied by 7 (e.g. 0,7,14,21,0,7,14,21...)
+## $1 day of the week (0-6)
+## /28 for 4 weeks
+
+echo "Scheduling " $2 " branch"
+if [ $2 = "master" ] ; then
+ # run master branch with --newest option looking for good sha1 7 builds back with /999 jobs
+ teuthology-suite -v -c $2 -m $3 -k distro -s $4 --subset $(echo "(($(date +%U) % 4) * 7) + $1" | bc)/999 --newest 7 -e $5 $6
+elif [ $2 = "hammer" ] ; then
+ # run hammer branch with less jobs
+ teuthology-suite -v -c $2 -m $3 -k distro -s $4 --subset $(echo "(($(date +%U) % 4) * 7) + $1" | bc)/56 -e $5 $6
+elif [ $2 = "jewel" ] ; then
+ # run jewel branch with /40 jobs
+ teuthology-suite -v -c $2 -m $3 -k distro -s $4 --subset $(echo "(($(date +%U) % 4) * 7) + $1" | bc)/40 -e $5 $6
+elif [ $2 = "kraken" ] ; then
+ # run kraken branch with /999 jobs
+ teuthology-suite -v -c $2 -m $3 -k distro -s $4 --subset $(echo "(($(date +%U) % 4) * 7) + $1" | bc)/999 -e $5 $6
+elif [ $2 = "luminous" ] ; then
+ # run luminous branch with /999 jobs
+ teuthology-suite -v -c $2 -m $3 -k distro -s $4 --subset $(echo "(($(date +%U) % 4) * 7) + $1" | bc)/999 -e $5 $6
+else
+ # run NON master branches without --newest
+ teuthology-suite -v -c $2 -m $3 -k distro -s $4 --subset $(echo "(($(date +%U) % 4) * 7) + $1" | bc)/28 -e $5 $6
+fi