]> xenbits.xensource.com Git - osstest.git/commitdiff
standalone: force an explicit default config flight-25929 flight-25932 flight-25935 flight-25937 flight-25940 flight-25943 flight-25946 flight-25949 flight-25952 flight-25954
authorIan Campbell <ian.campbell@citrix.com>
Mon, 14 Apr 2014 10:31:15 +0000 (11:31 +0100)
committerIan Jackson <Ian.Jackson@eu.citrix.com>
Sat, 19 Apr 2014 19:06:51 +0000 (20:06 +0100)
Some scripts (e.g. cri-args-hostlists) default to production-config instead of
the more expected ~/.xen-osstest/config. I keep forgetting this, so set the
more appropriate default in the helper script.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>
standalone

index 37c02946f2d7ea27935ddb628b532231ae7d5f53..8d9d88aaffd6f576e1f3ae4aceff6e7268071ae8 100755 (executable)
@@ -59,7 +59,7 @@ TEMP=$(getopt -o c:f:h:rR --long config:,flight:,host:,reuse,noreuse,reinstall,h
 
 eval set -- "$TEMP"
 
-config=
+config=$HOME/.xen-osstest/config
 flight="standalone"
 host=
 reuse=1 # Don't blow away machines by default
@@ -97,6 +97,11 @@ if [ ! -f standalone.db ] ; then
     exit 1
 fi
 
+if [ -z "$config" -o ! -r "$config" ] ; then
+    echo "Cannot read config." >&2
+    exit 1
+fi
+
 need_flight() {
     if [ -z "$flight" ] ; then
        echo "run-job: Need a flight" >&2