monitoros
v0.0.3
Published
An agent to monitor the operating system using Node.js and report to Dashi3
Downloads
4
Readme
Monitor OS
A program to monitor the operating system written in Node.js. Works with Dashi3
Install
npm install -g monitoros
## Usage
Configure the JSON file, name it whatever you want and move it to a location. Use the included options.json as a guide to write your own.
Run with:
monitoros -c /path/to/options.json
You can create an upstart job to load on boot
Options
{
"disk": {
"fileSystem": "/dev/disk0s2",
"uri": "http://local.luiselizondo.net/api/v1/data/mac-hard-drive"
},
"ram": {
"dangerLimit": "80",
"uri": "http://local.luiselizondo.net/api/v1/data/mac-memory"
},
"cpu": {
"uri": "http://local.luiselizondo.net/api/v1/data/mac-cpu"
},
"messages": {
"uri": "http://local.luiselizondo.net/api/v1/data/messages",
"image": "http://path-to-some-image",
"link": "http://path-to-some-link"
},
"access_token": "yfERm7mXNdRPV93am4a22ir9PcxHmExq5JW0H6gLez99o0pL5RRBX1pXwMp0X4Ai",
"delay": 60
}
*.uri: Path to where you want to save the data on Dashi3
disk.fileSystem: The disk to monitor, currently, only one disk can be monitored
ram.dangerLimit: The CPU percentage of used memory when an alert will be triggered (don't include the % sign). The alert will be of type messages.
access_token: The access token in Dashi3
delay: How often you want to run the program in seconds
Install Node.js and MonitorOS
wget -qO- https://raw.githubusercontent.com/iiiepe/monitoros/master/setup | sudo sh