correction when service failled

This commit is contained in:
vincent 2019-01-26 15:39:38 +01:00
parent 21d125c343
commit af7e726c06

View File

@ -12,12 +12,12 @@ for service in ${SERVICES[@]}
do
status=$(systemctl is-active $service)
if [ $status = "inactive" ]
if [ $status = "active" ]
then
echo -e "$service is $status"
echo $(journalctl -u $service --lines=10 -q)
else
echo -e "$service is $status"
echo $(journalctl -u $service --lines=10 -q)
fi
echo ""
done