Update cluster-update
This commit is contained in:
parent
f637c3bbc7
commit
284b6d909e
@ -1,13 +1,11 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
WORKER_LIST="worker.list"
|
WORKER_LIST="worker.list"
|
||||||
apt update
|
./update.sh
|
||||||
apt upgrade -y
|
|
||||||
for LINE in $(cat $WORKER_LIST | grep -vE "^#"); do
|
for LINE in $(cat $WORKER_LIST | grep -vE "^#"); do
|
||||||
WORKERNAME=`echo $LINE | awk -F"/" '{print $NF}'`
|
WORKERNAME=`echo $LINE | awk -F"/" '{print $NF}'`
|
||||||
|
|
||||||
echo "[worker:$WORKERNAME] Updating..."
|
echo "[worker:$WORKERNAME] Updating..."
|
||||||
ssh $WORKERNAME -o "StrictHostKeyChecking no" "bash -s" < apt update
|
ssh $WORKERNAME -o "StrictHostKeyChecking no" "bash -s" < ./update.sh
|
||||||
ssh $WORKERNAME -o "StrictHostKeyChecking no" "bash -s" < apt upgrade -y
|
|
||||||
|
|
||||||
echo "[worker:$WORKERNAME] Update is completed."
|
echo "[worker:$WORKERNAME] Update is completed."
|
||||||
done
|
done
|
||||||
|
Loading…
Reference in New Issue
Block a user