This is a pre-production deployment of Warehouse, however changes made here WILL affect the production instance of PyPI.
Latest Version Dependencies status unknown Test status unknown Test coverage unknown
Project Description
# django-monit-collector

This is a django project, which collects data from <a href="https://mmonit.com/monit/" target="_blank">monit</a> instances on one or multiple servers, stores them and visualizes them using <a href="http://getbootstrap.com/" target="_blank">bootstrap</a> and the javascript library <a href="http://dygraphs.com/" target="_blank">dygraphs</a>. Example website: http://monitcollector.cfs-me-research.net/monitcollector/server/5/

There is a very similar app for the server monitoring tool <a href="https://github.com/Supervisor/supervisor" target="_blank">supervisor</a> called <a href="https://github.com/nleng/djangovisor" target="_blank">djangovisor</a>.


### Features
- Collects and parses monit xml data from one or multiple servers.
- Stores the data for a given time period.
- Displays it in pretty graphs.
- Start/stop/restart buttons for processes.
- Status tables and graphs are refreshing automatically via ajax.
- Processes are automatically removed when they stop sending data (removed from monitrc). Servers can be deleted manually.

### Installation

Just install it via pip:
```
pip install django-monit-collector
```
Or clone the repository if you want to modify the code:
```
git clone https://github.com/nleng/django-monit-collector
```

Add 'monitcollector' to your installed apps in settings.py:
```
INSTALLED_APPS = [
'monitcollector',
# ...
]
```
If you want to you can change the default values in your settings.py:
```
# should be the same as set in the monitrc file e.g. "set daemon 60"
MONIT_UPDATE_PERIOD = 60
# maximum days to store data, only correct, if MONIT_UPDATE_PERIOD is set correctly
MAXIMUM_STORE_DAYS = 7
```
Include monitcollector in your url.py:
```
url(r'^monitcollector/', include('monitcollector.urls')),
```
In your monitrc file add this line to send data to the collector.
```
set mmonit http://mydomain.com/monitcollector/collector
```
If you want to enable the start/stop buttons (optional), the monit http daemon must be available, in monitrc (you can also )
```
set httpd port 2812
allow myuser:mypassword
```
If you don't want to allow access from everywhere add "allow ip.address..." with the ip address of the server, where monitcollector is installed.
The user and password have to be set in the settings.py:
```
ENABLE_BUTTONS = True
MONIT_USER = youruser
MONIT_PASSWORD = yourpassword
MONIT_PORT = 2812
```
You don't have to specify the port if you use the default port 2812. Also, the port must not me blocked by the firewall, e.g.
```
ufw allow 2812
```

You can also monitor this app with monit itself. Not using the privided script lead to error in my case.
```
check process monitcollector with pidfile /path/to/pid/gunicorn.pid
start program = "/project/path/gunicorn.sh start"
stop program = "/project/path/gunicorn.sh stop"
if failed host 127.0.0.1 port 8011 protocol http then restart
if 5 restarts within 5 cycles then alert
```
Then you should have the same port and pid path in your gunicorn.conf
```
bind = '127.0.0.1:8011'
...
pidfile = '/path/to/pid/gunicorn.pid'
```

### License
BSD License.
Release History

Release History

0.7

This version

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.6

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.5

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

Download Files

Download Files

TODO: Brief introduction on what you do with files - including link to relevant help section.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
django-monit-collector-0.7.tar.gz (167.4 kB) Copy SHA256 Checksum SHA256 Source Jun 2, 2015

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS HPE HPE Development Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting