terom@33: Manage DNS/bind9 zonefiles. terom@33: terom@33: update: terom@78: ./bin/update reads data from settings/, and generates zonefiles under var/zones/. terom@33: terom@33: `update` also shows and commits changes in settings/ data. terom@33: terom@56: -d DIR terom@34: Do data operations under given dir-root, as opposed to CWD. terom@34: terom@34: -q terom@56: Quiet. No log messages except errors. terom@34: terom@34: -vDV terom@34: Increasing logging verbosity. terom@34: terom@34: -p terom@56: Show diffs for changed output on stdout. terom@34: terom@34: -F terom@34: Force-update output files, even if newer than input files. terom@34: terom@34: -S terom@34: Do not generate new serials for zones. terom@34: terom@56: -s terom@56: Generate new serials for all zones. terom@56: terom@34: -n terom@34: Fake-update; show changes, but don't actually commit/deploy them. terom@34: terom@56: Useful for testing. terom@56: terom@34: -C terom@34: Do not commit source changes. terom@34: terom@34: -c terom@34: Force-commit source changes, even though -n terom@34: terom@56: -m MSG terom@34: Commit message for source changes; optional terom@34: terom@33: bin/update-serial: terom@33: Increment DNS SOA record serials in the given .serial files. terom@33: terom@33: Uses a YYYYMMDDXX format, but supports XX overflow. terom@33: terom@33: bin/process-zone: terom@33: Read zonefile containing records, and generate any of: terom@33: terom@33: --check-hosts: terom@33: Check for duplicate host names/IPs. terom@33: terom@33: --forward-zone: terom@33: Generate additional TXT/MX records to supplement A/CNAME records. terom@33: terom@33: --reverse-zone=NET terom@33: Generate PTR records for all matching A records. terom@33: terom@33: --meta-zone: terom@33: Generate additional TXT records from zonefile metadata, read from: terom@33: terom@33: hg annotate -q --date | ./bin/process-zone --input-line-date ... terom@33: terom@33: bin/expand-zone: terom@33: Expand template vars in a zone textfile; does not parse records, just passes through lines. terom@33: terom@33: Used to substitute e.g. `--serial .../foo.serial` values into SOA '{serial}' fields. terom@33: terom@33: bin/update: terom@33: Runs update-serial/process-zone/expand-zone to keep various generated zones/views up-to-date with respect to terom@56: source files under settings/. terom@33: terom@33: Also supports hg diff/commit/annotate integration with settings. terom@33: terom@56: Acts as our configuration file, determining the data/zones layout below. terom@56: terom@33: settings/: terom@33: Input files, fed through update to generate files under zones/ terom@33: terom@33: *.zone: terom@33: Zone header, passed through process-zone with `--serial *.serial` and any appropriate `--expand view=...`. terom@33: terom@33: May include a view-based $INCLUDE to include different zone data for different views. terom@33: terom@33: *.zone.*: terom@56: Include zonefiles, $INCLUDE'd from *.zone terom@33: terom@33: *.txt: terom@33: Hosts zone data, used to generate forwards/reverse -hosts zones terom@33: terom@78: var/ terom@78: Generated files. terom@33: terom@78: zones/: terom@78: Generated zonefiles, loaded by bind. terom@56: terom@78: common/* terom@78: Common zone files shared across views. terom@56: terom@78: hosts/*:$view terom@78: View-variant hosts zones generated from settings/*.txt terom@56: terom@78: hosts/* terom@78: Host zones generated from settings/*.txt, may be used in some views but not others. terom@78: terom@78: includes/*:$view terom@78: View-specific zone includes used from view/*. terom@78: terom@78: includes/*.* terom@78: Zone includes used from view/*. terom@78: terom@78: $view/* terom@78: Zone data for given zone/domain in given view terom@78: terom@78: $view/* -> ...: terom@78: Symlinked generic-zone data for some specific zone; either to common/* or $view/*. terom@78: terom@78: serials/*.serial terom@78: Zone serial numbers for corresponding zones/*/*.zone terom@78: