Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 19a400d2f3 |
@@ -1,2 +0,0 @@
|
||||
hosts="pine01.wks pine02.wks pine03.wks pine04.wks pine05.wks adm01.wks ebin01.wks ebin02.wks"
|
||||
domain="wks"
|
||||
@@ -1,12 +0,0 @@
|
||||
#!/bin/bash
|
||||
. hosts.conf
|
||||
|
||||
host=$1
|
||||
hostname=$(echo ${host} | sed s/\.${domain}//)
|
||||
MOSQ="mosquitto_pub -h mqtt.wks -t switch_cloud/switch/${hostname}/command -m"
|
||||
echo "${host} turning it off"
|
||||
${MOSQ} OFF
|
||||
sleep 2
|
||||
echo "${host} turning it on"
|
||||
${MOSQ} ON
|
||||
ping -W 1 ${host}
|
||||
@@ -1,13 +0,0 @@
|
||||
#!/bin/bash
|
||||
. hosts.conf
|
||||
for host in $hosts; do
|
||||
if ping -c 1 -W 1 "$host" >/dev/null; then
|
||||
echo "$host is alive"
|
||||
else
|
||||
echo "$host is pining for the fjords"
|
||||
fi
|
||||
done
|
||||
echo ''
|
||||
nomad server members
|
||||
echo ''
|
||||
nomad node status
|
||||
Reference in New Issue
Block a user