/kestrelweb

A kestrel web ui

Primary LanguageJavaScriptMIT LicenseMIT

kestrelweb

A kestrel web ui.

Uses gunicorn + gevent for front end serving. Also uses gevent to make async requests to the kestrel servers for stats. It's still in early development so any suggestions or ideas are welcome.

https://github.com/matterkkila/kestrelweb

Dependencies:

  • decoroute >= 0.8.1
  • gevent >= 0.13.6
  • gunicorn >= 0.13.4
  • pykestrel >= 0.5.1
  • webob >= 1.2b2

Prerequisites

  • Python 2.7+
  • virtualenv (not really required, but it's a good idea)
  • libevent 1.4+ (for gevent)

Installing

git clone https://github.com/matterkkila/kestrelweb.git
cd kestrelweb
virtualenv --no-site-packages .
. bin/activate
pip install -r requirement.txt
python ./setup.py develop

Note: If libevent is installed in a non-standard location (I'm looking at you macports) you'll need to download the source distribution for gevent and install using something similar to:

pip install --no-install gevent  #download only
cd build/gevent
python ./setup.py install --libevent /opt/local

Configuring

Copy the local_settings.py.example to local_settings.py and edit the server list to reflect your queue servers.

cp local_settings.py.example local_settings.py

Running

gunicorn -k gevent -w 2 kestrelweb.main:App

Deploying

It's best to front gunicorn with something like nginx. It is also best to use nginx to serve the static files used by kestrelweb. Specifically anything in /static/* should be served by the proxy server.

Filtering

You can filter the queue list on any field/value. Strings only support the '=' and '!=' comparisons and use the re.match() function. Numeric types support <, >, <=, >=, !=, = and will do the standard numeric comparison.

Examples:

  • queue=my_queue
  • queue!=.*_prod$
  • server=10.0.10
  • total_items>=10
  • mem_items<=1024

Feedback & Questions

Any comments, questions, feel free to send me a message on github at https://github.com/matterkkila

All patches and pull requests are welcome.