summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Adam <obnox@samba.org>2020-03-19 15:42:59 +0100
committerMichael Adam <obnox@samba.org>2020-03-20 12:29:37 +0100
commit51f2b643b5b0d73e8282656126a4b89381f082fb (patch)
treecfa37f66788f76bc08734e08c77a38ce2e407774
parent556a5110a5f3c017b50583377eeb939ee0f4404b (diff)
downloadsamba-integration-51f2b643b5b0d73e8282656126a4b89381f082fb.tar.gz
samba-integration-51f2b643b5b0d73e8282656126a4b89381f082fb.tar.xz
samba-integration-51f2b643b5b0d73e8282656126a4b89381f082fb.zip
centos-ci: add bootstrap.sh
Copied from https://github.com/heketi/ci-tests/blob/centos-ci/bootstrap.sh Signed-off-by: Michael Adam <obnox@samba.org>
-rwxr-xr-xbootstrap.sh12
1 files changed, 12 insertions, 0 deletions
diff --git a/bootstrap.sh b/bootstrap.sh
new file mode 100755
index 0000000..50e8673
--- /dev/null
+++ b/bootstrap.sh
@@ -0,0 +1,12 @@
+#!/bin/bash
+
+set -e
+set -x
+EXEC_BIN="$(basename $1)"
+scp -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no "$1" "root@$(cat $WORKSPACE/hosts):$EXEC_BIN"
+if [ -z $2 ];
+then
+ ssh -t -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no "root@$(cat $WORKSPACE/hosts)" "./$EXEC_BIN"
+else
+ ssh -t -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no "root@$(cat $WORKSPACE/hosts)" "$2" "./$EXEC_BIN"
+fi