add str running to parsed statuses
This commit is contained in:
parent
9fcaa5cfcb
commit
5ee37810ee
@ -1 +1 @@
|
|||||||
gcc main.c config.c -lcurl -Wall -I/usr/include/dbus-1.0 -I/usr/lib/dbus-1.0/include -ldbus-1
|
gcc main.c config.c -lcurl -Wall -I/usr/include/dbus-1.0 -I/usr/lib/dbus-1.0/include -ldbus-1 -o systemd-gotify.bin
|
||||||
|
1
config
1
config
@ -1,2 +1,3 @@
|
|||||||
/org/freedesktop/systemd1/unit/NetworkManager_2dwait_2donline_2eservice
|
/org/freedesktop/systemd1/unit/NetworkManager_2dwait_2donline_2eservice
|
||||||
/org/freedesktop/systemd1/unit/NetworkManager_2eservice
|
/org/freedesktop/systemd1/unit/NetworkManager_2eservice
|
||||||
|
/org/freedesktop/systemd1/unit/httpd_2eservice
|
||||||
|
2
main.c
2
main.c
@ -238,7 +238,7 @@ int checkState(char *ServiceName,char *result,Service *service)
|
|||||||
gotify_message("https://5ccppi.org:4433",ServiceName,"is not running");
|
gotify_message("https://5ccppi.org:4433",ServiceName,"is not running");
|
||||||
printf("!!system unit died!! Alert gotify server!\n");
|
printf("!!system unit died!! Alert gotify server!\n");
|
||||||
}
|
}
|
||||||
else if(strcmp(result,"active")==0)
|
else if(strcmp(result,"active")==0 || strcmp(result,"running")==0)
|
||||||
{
|
{
|
||||||
if(service->alerted == true)
|
if(service->alerted == true)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user