Unify info entry, make blacklist-file diffable

Signed-off-by: Knut Ahlers <knut@ahlers.me>
This commit is contained in:
Knut Ahlers 2020-02-15 14:32:46 +01:00
parent 1411cde2bd
commit 3f5e4a5a4a
Signed by: luzifer
GPG Key ID: DC2729FDD34BE99E
2 changed files with 6 additions and 7 deletions

View File

@ -22,10 +22,9 @@ This is quite easy:
```console
$ docker build -t personal-dns .
$ docker run --rm -ti -p 53:53 -p 53:53/udp personal-dns
$ dig +short @<ip of your container> TXT version.pdns.luzifer.io
"0ecb98c @ 2019-08-25 19:25:14 +00:00"
$ dig +short @<ip of your container> TXT count.pdns.luzifer.io
"128561"
$ dig +short @<ip of your container> TXT info.pdns.luzifer.io
"Entries: 128676"
"Build: 689a5e8 @ 2020-02-15 13:24:32 +00:00"
```
### Connect your computer to the container

View File

@ -138,12 +138,12 @@ template: |
; Healthcheck record - don't remove
health.pdns.luzifer.io A 127.0.1.1
version.pdns.luzifer.io TXT "{{ env `GIT_VERSION` }} @ {{ now `2006-01-02 15:04:05 -07:00` }}"
count.pdns.luzifer.io TXT "{{ len .blacklist }}"
info.pdns.luzifer.io TXT "Build: {{ env `GIT_VERSION` }} @ {{ now `2006-01-02 15:04:05 -07:00` }}"
info.pdns.luzifer.io TXT "Entries: {{ len .blacklist }}"
; Blacklist entries
{{ range .blacklist -}}
{{ to_punycode .Domain }} CNAME . ; {{ .Comment }}
{{ to_punycode .Domain }} CNAME . ; {{ join (sort .Comments) ", " }}
{{ end }}
...