blob: 99c00da33e1eccb3d88c541f07c2aac2d1eae17f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
#! /usr/bin/env bash
cmd_wait=$1
shift
sites=$*
donebit=0
while [ $donebit -ne 1 ]; do
sleep 10
donebit=1
for rem in $sites; do
rval=`ssh $rem ps aux | grep $cmd_wait | wc -l`
if [ $rval -gt 0 ]; then
donebit=0
fi
done
done
|