Skip to content

jochem/django-pdns

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 

Repository files navigation

django-pdns

Basic Django app that connects to the database used by the MySQL and PostgreSQL backends for PowerDNS.

Usage

Add 'pdns' to your INSTALLED_APPS and add a key 'powerdns' to the DATABASES dict in your projects' settings, e.g.:

DATABASES = {
    'default': {
        'ENGINE': 'django.db.backends.sqlite3',
        'NAME': os.path.join(BASE_DIR, 'db.sqlite3'),
    },
    'powerdns': {
        'ENGINE': 'django.db.backends.postgresql_psycopg2',
        'NAME': 'pdns',
        'USER': 'pdns',
        'PASSWORD': 'supercomplicatedpassword',
        'HOST': '127.0.0.1',
        'PORT': '5432',
    }
}

Finally, add pdns.routers.PowerDNSRouter to your DATABASE_ROUTERS list.

Notes

In the PowerDNS database, the primary key for the supermaster table is a combination of the ip and nameserver fields. Django does not support composite keys, therefore in this app the Supermaster model has its primary key on the nameserver attribute.

About

django-pdns

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •  

Languages