Python web application to get a dashboard of a bunch of Monit servers at a glance.
Main view when every Monit server hasn't found alerts:
One Monit agent is reporting an error on a server:
Expand the server with issues with errors on top:
Every 300 seconds (hardcoded) the application ask for the data served by the Monit built-in web server in a XML report from each configured server. Then, thanks to the built-in web server, it is displayed in a single HTML page.
apt install python-webpy
apt install python-xmltodict python-requests
yum install epel-release
yum install python-pip
pip install web.py
yum install python-requests python-xmltodict python-simplejson
pip install xlsxwriter
conf/servers.json
prior run. You might find a sample file at
conf/servers.json.example
.docker build -t monit-dashboard .
docker run -v $(pwd)/conf:/app/conf -p 8080:8080 monit-dashboard
./bin/monit-dashboard.py
By default, it will be reachable at http://localhost:8080. You might change
the port by adjusting app.run(port=8080)
in bin/monit-dashboard.py
file.
conf/servers.json
Sample settings as follows:
{
"My server to monit": {
"url": "http://example.com:2812",
"user": "monit",
"passwd": "*****"
}
}