Skip to main content

Use MongoDB URLs in your Django Application.

Project description

https://secure.travis-ci.org/ferrix/dj-mongohq-url.png?branch=master

This simple Django utility allows you to utilize the 12factor inspired MONGOURL_URL environment variable to configure your Django application.

This is a slight adaptation of the dj-database-url by Kenneth Reitz (http://github.com/kennethreitz/dj-database-url/). It is compatible with django-nonrel and can be used to dig up the URL setting for other purposes as well.

Usage

Configure your database in settings.py from DATABASE_URL:

DATABASES = {'default': dj_mongohq_url.config()}

Parse an arbitrary Database URL:

DATABASES = {'default': dj_mongohq_url.parse('mongodb://...')}

If you are not using Django with nonrel capabilities and merely want to dig up the MongoDB settings, use another variable:

MONGODB = dj_mongohq_url.config()

Supported databases

Support currently exists for MongoDB.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

dj_mongohq_url-0.0.3-py2-none-any.whl (4.0 kB view details)

Uploaded Python 2

File details

Details for the file dj_mongohq_url-0.0.3-py2-none-any.whl.

File metadata

File hashes

Hashes for dj_mongohq_url-0.0.3-py2-none-any.whl
Algorithm Hash digest
SHA256 99277cd6826280875b8fc34c5df2ef7e0bf1ef87f33b6e983e0fc339b05640fe
MD5 28e2ca02dda4e6e826d9fdb1ef614027
BLAKE2b-256 2ee5be2b8cce2ad9fcdf174aaeb566a6fc1781ff678468f8b185a7b008024652

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page