Update monitor.service

Added fix to show only the first network adapter in the case of multiples
This commit is contained in:
Beeranco 2023-08-15 17:20:36 +02:00 committed by GitHub
parent 10572130c8
commit 236901361a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -101,7 +101,7 @@ fi
# Variables # # Variables #
##-------------## ##-------------##
IP=`hostname -I` IP=`hostname -I` && IP=$(echo $IP | cut -d ' ' -f 1)
DATE=`date "+%d-%m-%y %H:%M"` DATE=`date "+%d-%m-%y %H:%M"`
CPUstat=`(top -bn1 | awk '/Cpu/ { print $2"%"}')` CPUstat=`(top -bn1 | awk '/Cpu/ { print $2"%"}')`
MEMstat=`(free -m | awk '/Mem/{print $3"MB"}')` MEMstat=`(free -m | awk '/Mem/{print $3"MB"}')`