Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/torxed/powerdns_updater

pdns dynamic updater and admin interface
https://github.com/torxed/powerdns_updater

Last synced: about 11 hours ago
JSON representation

pdns dynamic updater and admin interface

Awesome Lists containing this project

README

        

PowerDNS Updater
================
This is a toolkit for creating, updating and maintaining PowerDNS 3.2+

local_tool
----------

Launch by: `user@host ~$ python local_tool.py /path/to/database.sqlite`

The local tool is a small CLI that interacts with the backend.

It consists of a few short "commands" that executes backend functions.

And these are the following commands:

* add [domain|record]
* modify
* replace

With these short commands you'll the the options to add a record or domain,

modify a existing record via name specification or replace old ip's with new ones.

backend
-------

The backend is mainly a wrapper for traditional SQL statements.

This will be a shared module that any script or tool can import

and execute simple tasks on the PowerDNS SQL database structure,

such as:

* Creating a brand new database
* Adding domains
* Adding record
* Modifying records based on type and name
* Renew all IP records with a new IP (`replace(old_ip, new_ip)`)

More "features" will come, mainly for DNSSEC but for now these are

the tasks that are simplified by having taken the manual tasks and

replaced them with functions within the `SQL()` class.

The Backend also relies on `sql_createdb.py-sqlite` for syntax.

Since sqlite3 in Python doesn't handle multiple queries well enough

in one execution the SQL statements are divided by `%%` between each

statement and within the backend.py it just takes `data.split('%%')`

and executes one query at a time.