sophie e7820e8bf0 | ||
---|---|---|
lib | ||
.gitignore | ||
LICENSE | ||
README.md | ||
conf.json | ||
conf.server.json | ||
index.js | ||
lighthouse.service | ||
package.json |
README.md
lighthouse
simple network status monitor
configuration
conf.json
{
"server": true,
"site": "zvava.org",
"path": "/api/lighthouse",
"token": "a1b2c3d4etc",
"this": {
"name": "zvavnet",
"checkInterval": 20,
"reportedServices": [
"agate",
"caddy",
...
]
}
}
server
decides if the server should be hosted in addition to collecting its own statistics
site
is the domain of your lighthouse server
path
is the path to the api endpoint on your server's domain
token
verifies clients to a server, should be same on all devices across your network
this.name
name of this device in the network
this.checkInterval
how often to check the status of local services (in seconds)
this.reportedServices
array of the names of systemd services to report status and uptime of
conf.server.json
{
"apiPort": 8002,
"fePort": 8003,
"cacheDB": ".status-cache.json",
"saveTimeout": 5,
"handshakeInterval": 90,
"handshakeTimeout": 240
}
apiPort
port the service is hosted on
fePort
port the frontend is exposed on, set to -1 (≤ 0) to disable the frontend
cacheDB
filename for the cache of monitor statuses
saveTimeout
period to elapse before an update to the network status is saved to disk (in seconds)
handshakeTimeout
time between handshakes before a client is deemed offline (in seconds)
handshakeInterval
time expected between handshakes (in seconds) sent when a device is registered