I have a Django webapp, and I\'d like to check if it\'s running on the Heroku stack (for conditional enabling of debugging, etc.) Is there any simple way to do this? An envi
An ENV var seems to the most obvious way of doing this. Either look for an ENV var that you know exists, or set your own:
on_heroku = False if 'YOUR_ENV_VAR' in os.environ: on_heroku = True
more at: http://devcenter.heroku.com/articles/config-vars