Skip to content
This repository has been archived by the owner on Feb 26, 2020. It is now read-only.

alexluke/AWS-load-balancer-status

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

AWS Load Balancer Status

A status page for monitoring instances attached to an elastic load balancer.

Setup

Create a settings.cfg file like the following:

ACCESS_KEY = 'your_aws_access_key'
SECRET_KEY = 'your aws_secret_key'
# A list of load balancers you want to monitor
LOAD_BALANCERS = [
	'name_of_elb1',
	'name_of_elb2',
]

Create a virtualenv and install required packages:

$ virtualenv venv --distribute
$ pip -E venv install -r requirements.txt

Deploy

mod_wsgi

Create an application.wsgi file:

import sys
sys.path.insert(0, '/path/to/application')
activate_this = '/path/to/app/venv/bin/activate_this.py'
execfile(activate_this, dict(__file__=activate_this))
from monitor import app as application

Create an apache vhost file:

<VirtualHost *>
	ServerName example.com

	WSGIDaemonProcess lb_monitor user=www-data group=www-data threads=5
	WSGIScriptAlias / /path/to/app/application.wsgi

	<Directory /path/to/app>
		WSGIProcessGroup lb_monitor
		WSGIApplicationGroup %{GLOBAL}
		WSGIScriptReloading On
		Order deny,allow
		Allow from all
	</Directory>
</VirtualHost>

See the Flask deployment documentation for other WSGI servers.

About

A status page for monitoring instances attached to an elastic load balancer

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages