I hereby claim:
- I am tylerdave on github.
- I am tylerdave (https://keybase.io/tylerdave) on keybase.
- I have a public key whose fingerprint is E6F7 DEB7 BE04 9C44 D6F0 CFF9 CAF1 D82B AC5A 918F
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
# I'm starting with a clean CentoOS 6.5 install on Rackspace Cloud (which includes EPEL by default.) | |
# Install yum packages | |
# TODO: Install Python stuff into virtualenv rather than from yum packages | |
yum -y install python-whisper python-carbon graphite-web python-memcached python-ldap httpd memcached python-bucky | |
# ===== BEGIN MANUAL STEP ===== | |
# run syncdb to setup the db and prime the authentication model (if you're using the DB model) | |
python /usr/lib/python2.6/site-packages/graphite/manage.py syncdb | |
# ===== END MANUAL STEP ===== |
import requests | |
def _resolve_redirected_url(url): | |
response = requests.get(url, allow_redirects=False) | |
if response.status_code in [301, 302, 307, 308] and 'location' in response.headers: | |
url = response.headers['location'] | |
return url |
import time | |
class Retry(object): | |
default_exceptions = (Exception) | |
def __init__(self, tries, exceptions=None, delay=0): | |
""" | |
Decorator for retrying function if exception occurs | |
tries -- num tries | |
exceptions -- exceptions to catch |