Host Alive

project details

Host Alive

This is a small Node.js project to ping a host/url with a few options and can be used to monitor a device or server.


The project is written with Node.js and uses the net-ping library. The project also uses the pushover-notifications library for sending push notifications.


To start the app you first have to set a few settings in the .env variables. According to the example of the .env.example, the mode and the target is set there. HOST is the host to ping (it can be either an IP address or a url). REPEAT / CONTINOUS determines how often or whether pinging should be permanent. If a notification is to be sent in case of an unsuccessful ping, the pushover token can also be entered.


After that, the app can be launched as a console application. If a url was specified as the target, an attempt is first made to resolve the IP address. Now the pings are sent and the runtimes are displayed. If several pings in a row fail within a certain period, a notification will be sent to the user via Pushover with a report.


You can find the project on GitHub and is open source.

Images