https://github.com/torxed/powerdns_updater
pdns dynamic updater and admin interface
https://github.com/torxed/powerdns_updater
Last synced: 2 months ago
JSON representation
pdns dynamic updater and admin interface
- Host: GitHub
- URL: https://github.com/torxed/powerdns_updater
- Owner: Torxed
- Created: 2013-05-08T11:26:29.000Z (about 12 years ago)
- Default Branch: master
- Last Pushed: 2015-01-01T20:30:08.000Z (over 10 years ago)
- Last Synced: 2025-01-25T17:08:56.595Z (4 months ago)
- Language: Python
- Size: 138 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
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
* replaceWith 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.