django-heroku-postgresify

Software Screenshot:
django-heroku-postgresify
Software Details:
Version: 0.2
Upload Date: 14 Apr 15
Developer: Randall Degges
Distribution Type: Freeware
Downloads: 20

Rating: 5.0/5 (Total Votes: 1)

django-heroku-postgresify is a Django app that provides automatic Django database configuration on Heroku.

 Install

To install ``django-heroku-postgresify``, simply run ``pip install django-heroku-postgresify`` and you'll get the latest version installed automatically.

Usage

Modify your Django ``settings.py`` file, and set:

``` python
from postgresify import postgresify

DATABASES = postgresify()
```


That's it.

Depending on the Heroku PostgreSQL databases you've got installed, your ``DATABASES`` configuration will automatically be setup to use them.

For example, let's assume you've got the following environment variables set on Heroku (you can view the list of all environment variables by running ``heroku config``):

- ``HEROKU_POSTGRESQL_BLUE_URL``
- ``HEROKU_POSTGRESQL_RED_URL``
- ``SHARED_DATABASE_URL``
- ``DATABASE_URL``


Your ``DATABASES`` setting would be:

``` python
DATABASES = {
    'default': {
        # DATABASE_URL configs here
    },
    'SHARED': {
        # SHARED_DATABASE_URL configs here
    },
    'BLUE': {
        # HEROKU_POSTGRESQL_BLUE_URL configs here
    },
    'RED': {
        # HEROKU_POSTGRESQL_RED_URL configs here
    },
}
```

Requirements:

  • Python
  • Django

Other Software of Developer Randall Degges

django-sslify
django-sslify

14 Apr 15

django-clear-cache
django-clear-cache

14 Apr 15

amazonify
amazonify

14 Apr 15

Comments to django-heroku-postgresify

Comments not found
Add Comment
Turn on images!