show state of router and frappy service at welcome
This commit is contained in:
@ -1,3 +1,9 @@
|
||||
echo "Welcome to $HOSTNAME $(hostname -I)"
|
||||
echo "$(cat /sys/class/net/enp4s0/address)"
|
||||
export EDITOR=nano
|
||||
function service_status () {
|
||||
for name in $@; do \
|
||||
echo ${name} $(systemctl is-active ${name}) $(systemctl is-enabled ${name}); \
|
||||
done | column -t | grep --color=always '\(disabled\|inactive\|$\)'
|
||||
}
|
||||
service_status router frappy
|
||||
|
Reference in New Issue
Block a user