Giter Site home page Giter Site logo

django-monit's Introduction

django-monit - A Simple Monit Collector

Warning

django-monit is currently very preliminary and is best for people who are comfortable installing reusable apps in Django projects.

django-monit is a very dumb (but free) replacement for M/Monit, the commerical product built around the amazing Monit management and monitoring tool.

django-monit is a reusable Django application providing a central Monit "collector" and storage of the Monit nodes' information and events. Currently, django-monit can be installed as an app within an existing Django site. In the future, a tool could build a simple Django project if someone wished to only deploy django-monit.

At this point, django-monit only acts as a collector of information from any number of Monit nodes, and can not push restart commands to the nodes as M/Monit can do.

My goal currently is to create a tool for making Monit data easily accessible from a Django project, rather than acting as a replacement for M/Monit.

django-monit has been tested on the Django 1.2 trunk using Monit 5.0.3 provided as a Ubuntu 9.10 package.

Installation

The easiest way to install django-monit is via pip:

pip install django-monit

Add 'monit' to the INSTALLED_APPS in your settings.py

Add url(r'^monit/', include('monit.urls')) in your urls.py:

urlpatterns = patterns('',
    url(r'^app/', include('yourapp.urls')),
    url(r'^monit/', include('monit.urls')),
    (r'^admin/', include(admin.site.urls)),
)

Configure Monit

In the monitrc, you should configure your django-monit instance as a collector:

set mmonit http://monit:[email protected]:8000/monit/collector

Dependencies

  • Django (tested on pre-1.2 trunk)
  • lxml

Testing

If you have checked out the source, you can run the test suite, which uses a simple Django project in the test_project folder:

cd test_project
# create a virtualenv and install the dependencies
create_env.sh
# run the tests
./manage.py test monit

Running in Django 1.8

Quick and hacky way to run this app in Django 1.8

Copy the monit folder into the Django project and follow the installation instructions above. Also create migrations as follows:

python manage.py makemigrations monit
python manage.py migrate

django-monit's People

Contributors

johnpaulett avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.