Revision 27cc0deb

View differences:

rsync-ignore
1
results/
2
.git/
3
*.swp
4
*_results/
rsync-master-node.sh
1
#!/usr/bin/env bash
2

  
3
if [ $# -eq 1 ]; then
4
	testbed="$1"
5
else
6
	testbed="twist"
7
fi
8

  
9
. ./setenv.sh $testbed
10

  
11
IOF_FOLDER=${HOME_FOLDER}/iof-tools/
12

  
13
ssh -F ${CONFIG_FILE} ${MASTER_NODE} "mkdir -p ${IOF_FOLDER}"
14
rsync -avcz --exclude-from=rsync-ignore -e "ssh -F ${CONFIG_FILE} -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null" --progress ./ ${MASTER_NODE}:${IOF_FOLDER}
run
1
#!/usr/bin/env bash
2

  
3
testbed_exists=`echo $@ | grep testbed`
4
if [ "$testbed_exists" == "" ]; then
5
	testbed="twist"
6
else
7
	testbed=`echo $@ | sed -e "s/^.*testbed=\([a-zA-Z0-9]\+\).*$/\1/g"`
8
fi
9

  
10
. ./setenv.sh $testbed
11

  
12
if [ $# -ge 1 ]; then
13
	playbook=$1
14
	if [ $# -ge 2 ]; then
15
		shift
16
		args="--extra-vars \"$@\""
17
	fi
18
else
19
	playbook=echo-hostname.yaml
20
	args=""
21
fi
22

  
23
IOF_FOLDER=${HOME_FOLDER}/iof-tools/
24

  
25
ssh -A -F ${CONFIG_FILE} ${MASTER_NODE} "bash -ic 'cd ${IOF_FOLDER} && ansible-playbook $playbook $args'"
setenv.sh
1
if [ $# -eq 1 ]; then
2
	testbed="$1"
3
else
4
	testbed="twist"
5
fi
6

  
7
if [ "$testbed" == "wilab" ]; then
8
	MASTER_NODE=nuc0-43
9
	CONFIG_FILE=$HOME/.ssh/wilab1-ssh.cfg
10
elif [ "$testbed" == "twist" ]; then
11
	MASTER_NODE=nuc4
12
	CONFIG_FILE=$HOME/.ssh/twist-ssh.cfg
13
else
14
	MASTER_NODE=proxy0
15
	CONFIG_FILE=./ssh-config
16
fi
17

  
18
HOME_FOLDER=`ssh -F ${CONFIG_FILE} ${MASTER_NODE} "pwd"`

Also available in: Unified diff