mirror of
https://github.com/telekom-security/tpotce.git
synced 2025-06-30 20:12:11 +00:00
tweaking dps.sh
This commit is contained in:
parent
a90f7cdf23
commit
bd29236c47
1 changed files with 16 additions and 1 deletions
|
@ -1,2 +1,17 @@
|
|||
#/bin/bash
|
||||
docker ps --format "table {{.Names}}\t{{.Status}}\t{{.Ports}}" -f status=running -f status=exited | GREP_COLORS='mt=01;35' egrep --color=always "(^[_a-z-]+ |$)|$" | GREP_COLORS='mt=01;32' egrep --color=always "(Up[ 0-9a-Z ]+ |$)|$" | GREP_COLORS='mt=01;31' egrep --color=always "(Exited[ \(0-9\) ]+ [0-9a-Z ]+ ago|$)|$"
|
||||
while true
|
||||
do
|
||||
clear
|
||||
echo "======| System |======"
|
||||
echo Date:" "$(date)
|
||||
echo Uptime:" "$(uptime)
|
||||
echo CPU temp: $(sensors | grep "Physical" | awk '{ print $4 }')
|
||||
echo
|
||||
/usr/bin/docker ps --format "table {{.Names}}\t{{.Status}}\t{{.Ports}}" -f status=running -f status=exited | GREP_COLORS='mt=01;35' /bin/egrep --color=always "(^[_a-z-]+ |$)|$" | GREP_COLORS='mt=01;32' /bin/egrep --color=always "(Up[ 0-9a-Z ]+ |$)|$" | GREP_COLORS='mt=01;31' /bin/egrep --color=always "(Exited[ \(0-9\) ]+ [0-9a-Z ]+ ago|$)|$"
|
||||
if [ "$1" = "" ];
|
||||
then
|
||||
break;
|
||||
else
|
||||
sleep $1
|
||||
fi
|
||||
done
|
||||
|
|
Loading…
Reference in a new issue