Add 'doit.sh'
This commit is contained in:
parent
7cdbd6b77d
commit
78d758a85d
24
doit.sh
Normal file
24
doit.sh
Normal file
@ -0,0 +1,24 @@
|
||||
#!/bin/bash
|
||||
|
||||
if [ $# -gt 0 ]; then
|
||||
for h in $*; do
|
||||
hosts="$hosts `dig +short +search $h`"
|
||||
done
|
||||
else
|
||||
hosts=`awk '/^[0-9]+.*# # Linux/ { print $2; }' /usr/local/bb/etc/bb-hosts`
|
||||
fi
|
||||
|
||||
for h in $hosts ; do
|
||||
echo "$h (`host $h | awk '{print $5;}'`)"
|
||||
scp /usr/local/operations/linux/evault/Agent-Linux-latest.tar.gz $h:
|
||||
ssh -qT $h <<EOF
|
||||
tar zxvpCf /tmp Agent-Linux-latest.tar.gz
|
||||
(
|
||||
cd /tmp/Agent+WCC-6.73.3196-Linux-i386-stdc++v3_6
|
||||
echo n > no
|
||||
./install.sh -s -D < no
|
||||
)
|
||||
rm -rf /tmp/Agent+WCC-6.73.3196-Linux-i386-stdc++v3_6
|
||||
rm -f Agent-Linux-latest.tar.gz
|
||||
EOF
|
||||
done
|
Loading…
x
Reference in New Issue
Block a user