Anonymous avatar Anonymous committed aed2d12

Fixing scripts for multiple vabs monitoring slaves to work with their own repos in different paths

Comments (0)

Files changed (2)

slave/sbin/ro-chrootTEST

 source /etc/vlbuildslave/slavehost.conf
 
 if [ -z "$GITREPO" ]; then
-	echo "GITREPO variable is empty.  This needs to point to the repo we are using" >&2
+	echo "$0 Error: GITREPO variable is empty.  This needs to point to the repo we are using" >&2
 	exit 1
 fi
 exit_status=""

slave/usr/local/bin/changetest.sh

 exit 1
 }
 
+if [ ! -d $GITREPO/.git ]; then
+	exit_error "$0 Error: $GITREPO does not appear to be a git repository.  Aborting build"
+	exit 1
+fi
+
+export GITREPO=$GITREPO
+
 source $CONF || exit_error "Unable to source $CONF"
 
 function get_jail_path {
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.