This is an automated email from the git hooks/post-receive script.
bernie.ogden pushed a commit to branch lastwibbles in repository toolchain/lavabench.
commit 756cb43927218b8da8543a7a737226762896a32e Author: Bernard Ogden bernie.ogden@linaro.org Date: Tue Jul 28 11:14:05 2015 +0200
Tear out all the hacking-session-isms
Change-Id: Id4f704c6c69d851f9d6b473d0b8dd237d9d236af --- bench-session | 13 ++++++ bench-session-debian.yaml => bench-session.yaml | 9 ++--- invoke_session_debian | 54 ------------------------- setup_session_debian | 14 ------- stop_hacking_debian | 5 --- 5 files changed, 16 insertions(+), 79 deletions(-)
diff --git a/bench-session b/bench-session new file mode 100755 index 0000000..525ef52 --- /dev/null +++ b/bench-session @@ -0,0 +1,13 @@ +#!/bin/bash +mkdir -p ~/.ssh/ +echo $1 >> ~/.ssh/authorized_keys +echo "Public Key Installed: $1" + +/etc/init.d/ssh restart +echo "sshd re-started" + +echo "Hostname for early debugging: $(cat /etc/hostname)" +echo "IP address for early debugging: $(hostname -I)" + +lava-network broadcast eth0 +sleep infinity diff --git a/bench-session-debian.yaml b/bench-session.yaml similarity index 59% rename from bench-session-debian.yaml rename to bench-session.yaml index 85a0a81..f8d09a5 100644 --- a/bench-session-debian.yaml +++ b/bench-session.yaml @@ -1,14 +1,11 @@ metadata: - name: bench-session-debian + name: bench-session format: "Lava-Test-Shell Test Definition 1.0" description: "Benchmarking Session" version: 1.0
params: PUB_KEY: None - GATEWAY: 10.0.0.1 - LISTENER_ADDR: NONE - LISTENER_PORT: NONE
install: deps: @@ -20,7 +17,7 @@ install: - gawk - libgfortran3 - rsync + run: steps: - - ./setup_session_debian "$PUB_KEY" - - ./invoke_session_debian "$GATEWAY" "$LISTENER_ADDR" "$LISTENER_PORT" + - ./bench-session "$PUB_KEY" diff --git a/invoke_session_debian b/invoke_session_debian deleted file mode 100755 index 654bbbe..0000000 --- a/invoke_session_debian +++ /dev/null @@ -1,54 +0,0 @@ -#!/bin/bash -# Usage ./invoke_session <gateway> - -# Hack for now until lava-test-shell is smart enough to know it's dispatcher ip -gateway=$1 -listener_addr=$2 -listener_port=$3 -echo "Target's Gateway: $gateway" - -if ! grep 'invoke_session' /etc/rc.local -then - sed -i '/bin/a invoke_session &' /etc/rc.local -fi - -# Obtain target IP and Hostname -ip_addr=$(ifconfig `ip route get $gateway | cut -d ' ' -f3` | grep 'inet addr' |aw [...] -hostname=$(cat /etc/hostname) - -# Set the PATH to use the LAVA api -echo "export PATH=/lava/bin/:$PATH" > ~/.bashrc - -echo "" -echo "" -echo "**************************************************************************** [...] -echo -n "Please connect to: " -echo -n "ssh " -echo -n "-o UserKnownHostsFile=/dev/null " -echo -n "-o StrictHostKeyChecking=no " -echo -n "root@" -echo -n $ip_addr -echo -n " " -echo -n "(" -echo -n $hostname -echo ")" -echo "**************************************************************************** [...] -echo "" -echo "" -mkdir -p /run -mkdir -p /run/hacking -echo $$ > /run/hacking/hacking.pid - -lava-network broadcast eth0 - -#suspend in a way that is portable across shells and doesn't involve a busy-wait -pid= -trap 'kill $pid - trap - SIGCONT' SIGCONT -echo "Benchmarking session active..." -sleep 999d& #timeout after 2 or 3 years... the job is likely to have a rather shor [...] -pid=$! -wait - -echo "Benchmarking session ended..." -echo "<LAVA_TEST_RUNNER>: exiting" diff --git a/setup_session_debian b/setup_session_debian deleted file mode 100755 index 4352d2d..0000000 --- a/setup_session_debian +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/bash -# Usage ./setup_session <pub_key> - -chmod a+x stop_hacking_debian -cp stop_hacking_debian /bin/stop_hacking -chmod a+x invoke_session_debian -cp invoke_session_debian /bin/invoke_session - -mkdir -p ~/.ssh/ -echo $1 >> ~/.ssh/authorized_keys -echo "Public Key Installed: $1" - -/etc/init.d/ssh restart -echo "sshd re-started" diff --git a/stop_hacking_debian b/stop_hacking_debian deleted file mode 100755 index a872268..0000000 --- a/stop_hacking_debian +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/bash -kill -CONT `cat /run/hacking/hacking.pid` -rm -f /run/hacking/hacking.pid -rm ~/.ssh/authorized_keys -/etc/init.d/ssh stop