Mercurial > hg > anonet-resdb
annotate scripts/nameserver_autogen/tinydns_tld_datafile @ 125:18ac7e165dde draft
Revert "Added atomictorrent repo, and added multirepo support for pragmo:"
This reverts commit a4873c43c2d49ddfc02143a38257e774c5f578a2, but undoes
the revert for all the documented changes above. The only change that
stays reverted is the (undocumented) change to the tinydns autogen script.
If you want the tinydns autogen script to output your own NS instead
of mine (the default), the correct thing to do is to change your own
configuration (for example, by running ./configure). Starting an editing
war with everybody else who's too lazy to configure and decides to pull
the same stunt you did doesn't help anyone, since the whole lot of you
will be constantly stepping all over each other. I believe my NS is
the most sane default, so I think it should stay. If I'm wrong, feel
free to revert my revert of your commit, but if you're going to do a
commit that's likely to cause controversy, it'd be nice to explain your
reasons in the commit message, rather than just trying to slip it under
the radar by bundling it in with another commit and not even mentioning
it in the log. (Remember: I can't read your mind, so I don't think
it's fair for you to expect me to know you're right, even if you are.
I'm just not smart enough to know why you're right.)
author | Nick <nick@somerandomnick.ano> |
---|---|
date | Sun, 29 Aug 2010 12:22:41 +0000 |
parents | fa0053d4cb53 |
children | d9b51927d97e |
rev | line source |
---|---|
12
41b330b11a33
coded a tinydns datafile generator
Nick <nick@somerandomnick.ano>
parents:
diff
changeset
|
1 #!/bin/sh |
41b330b11a33
coded a tinydns datafile generator
Nick <nick@somerandomnick.ano>
parents:
diff
changeset
|
2 if ! ./scripts/check_db_safety; then |
41b330b11a33
coded a tinydns datafile generator
Nick <nick@somerandomnick.ano>
parents:
diff
changeset
|
3 exit 1 |
41b330b11a33
coded a tinydns datafile generator
Nick <nick@somerandomnick.ano>
parents:
diff
changeset
|
4 fi |
125
18ac7e165dde
Revert "Added atomictorrent repo, and added multirepo support for pragmo:"
Nick <nick@somerandomnick.ano>
parents:
122
diff
changeset
|
5 tldsrvrname="$(./scripts/conf_var tinydns__tldsrvrname uz5fvb7zdqyuz4q8ysjdfuf04kzd2lrt0l6fp4uyguxdg5tfut06ck.anons.somerandomnick.ano)" |
18ac7e165dde
Revert "Added atomictorrent repo, and added multirepo support for pragmo:"
Nick <nick@somerandomnick.ano>
parents:
122
diff
changeset
|
6 tldsrvrip="$(./scripts/conf_var tinydns__tldsrvrip 1.0.27.37)" |
79
9a0e9ee425cc
bug fixes for tinydns datafile generation (thanks again, Quintum)
Nick <nick@somerandomnick.ano>
parents:
13
diff
changeset
|
7 for tld in db/ip/?? ; do |
9a0e9ee425cc
bug fixes for tinydns datafile generation (thanks again, Quintum)
Nick <nick@somerandomnick.ano>
parents:
13
diff
changeset
|
8 if [ "x$(basename $tld)" != 'x??' ]; then |
9a0e9ee425cc
bug fixes for tinydns datafile generation (thanks again, Quintum)
Nick <nick@somerandomnick.ano>
parents:
13
diff
changeset
|
9 first="$(basename $tld | ./scripts/hex2dec)" |
9a0e9ee425cc
bug fixes for tinydns datafile generation (thanks again, Quintum)
Nick <nick@somerandomnick.ano>
parents:
13
diff
changeset
|
10 tldname="$first.in-addr.arpa" |
9a0e9ee425cc
bug fixes for tinydns datafile generation (thanks again, Quintum)
Nick <nick@somerandomnick.ano>
parents:
13
diff
changeset
|
11 echo "+$tldsrvrname:$tldsrvrip:3600" |
9a0e9ee425cc
bug fixes for tinydns datafile generation (thanks again, Quintum)
Nick <nick@somerandomnick.ano>
parents:
13
diff
changeset
|
12 echo ".$tldname::$tldsrvrname" |
9a0e9ee425cc
bug fixes for tinydns datafile generation (thanks again, Quintum)
Nick <nick@somerandomnick.ano>
parents:
13
diff
changeset
|
13 for ip in $tld/??/?? ; do |
9a0e9ee425cc
bug fixes for tinydns datafile generation (thanks again, Quintum)
Nick <nick@somerandomnick.ano>
parents:
13
diff
changeset
|
14 if [ "x$(basename $ip)" != 'x??' ]; then |
9a0e9ee425cc
bug fixes for tinydns datafile generation (thanks again, Quintum)
Nick <nick@somerandomnick.ano>
parents:
13
diff
changeset
|
15 third="$(basename $ip | ./scripts/hex2dec)" |
9a0e9ee425cc
bug fixes for tinydns datafile generation (thanks again, Quintum)
Nick <nick@somerandomnick.ano>
parents:
13
diff
changeset
|
16 second="$(basename $(dirname $ip) | ./scripts/hex2dec)" |
9a0e9ee425cc
bug fixes for tinydns datafile generation (thanks again, Quintum)
Nick <nick@somerandomnick.ano>
parents:
13
diff
changeset
|
17 first="$(basename $(dirname $(dirname $ip)) | ./scripts/hex2dec)" |
9a0e9ee425cc
bug fixes for tinydns datafile generation (thanks again, Quintum)
Nick <nick@somerandomnick.ano>
parents:
13
diff
changeset
|
18 domain="$third.$second.$first.in-addr.arpa" |
9a0e9ee425cc
bug fixes for tinydns datafile generation (thanks again, Quintum)
Nick <nick@somerandomnick.ano>
parents:
13
diff
changeset
|
19 for ns in $ip/ns/* ; do |
9a0e9ee425cc
bug fixes for tinydns datafile generation (thanks again, Quintum)
Nick <nick@somerandomnick.ano>
parents:
13
diff
changeset
|
20 nsname="$(basename $ns)" |
9a0e9ee425cc
bug fixes for tinydns datafile generation (thanks again, Quintum)
Nick <nick@somerandomnick.ano>
parents:
13
diff
changeset
|
21 if [ "x$nsname" != 'x*' ]; then |
9a0e9ee425cc
bug fixes for tinydns datafile generation (thanks again, Quintum)
Nick <nick@somerandomnick.ano>
parents:
13
diff
changeset
|
22 nsip="$(cat $ns)" |
9a0e9ee425cc
bug fixes for tinydns datafile generation (thanks again, Quintum)
Nick <nick@somerandomnick.ano>
parents:
13
diff
changeset
|
23 echo "&$domain:$nsip:$nsname" |
9a0e9ee425cc
bug fixes for tinydns datafile generation (thanks again, Quintum)
Nick <nick@somerandomnick.ano>
parents:
13
diff
changeset
|
24 fi |
9a0e9ee425cc
bug fixes for tinydns datafile generation (thanks again, Quintum)
Nick <nick@somerandomnick.ano>
parents:
13
diff
changeset
|
25 done |
9a0e9ee425cc
bug fixes for tinydns datafile generation (thanks again, Quintum)
Nick <nick@somerandomnick.ano>
parents:
13
diff
changeset
|
26 fi |
13
059b5f3d7808
added rDNS to tinydns datafile generation
Nick <nick@somerandomnick.ano>
parents:
12
diff
changeset
|
27 done |
79
9a0e9ee425cc
bug fixes for tinydns datafile generation (thanks again, Quintum)
Nick <nick@somerandomnick.ano>
parents:
13
diff
changeset
|
28 fi |
13
059b5f3d7808
added rDNS to tinydns datafile generation
Nick <nick@somerandomnick.ano>
parents:
12
diff
changeset
|
29 done |
12
41b330b11a33
coded a tinydns datafile generator
Nick <nick@somerandomnick.ano>
parents:
diff
changeset
|
30 for tld in db/dom/* ; do |
41b330b11a33
coded a tinydns datafile generator
Nick <nick@somerandomnick.ano>
parents:
diff
changeset
|
31 tldname="$(basename $tld)" |
41b330b11a33
coded a tinydns datafile generator
Nick <nick@somerandomnick.ano>
parents:
diff
changeset
|
32 echo "+$tldsrvrname:$tldsrvrip:3600" |
41b330b11a33
coded a tinydns datafile generator
Nick <nick@somerandomnick.ano>
parents:
diff
changeset
|
33 echo ".$tldname::$tldsrvrname" |
41b330b11a33
coded a tinydns datafile generator
Nick <nick@somerandomnick.ano>
parents:
diff
changeset
|
34 for zone in $tld/* ; do |
41b330b11a33
coded a tinydns datafile generator
Nick <nick@somerandomnick.ano>
parents:
diff
changeset
|
35 for ns in $zone/ns/* ; do |
41b330b11a33
coded a tinydns datafile generator
Nick <nick@somerandomnick.ano>
parents:
diff
changeset
|
36 domain="$(basename $zone).$(basename $tld)" |
41b330b11a33
coded a tinydns datafile generator
Nick <nick@somerandomnick.ano>
parents:
diff
changeset
|
37 nsip="$(cat $ns)" |
41b330b11a33
coded a tinydns datafile generator
Nick <nick@somerandomnick.ano>
parents:
diff
changeset
|
38 nsname="$(basename $ns)" |
41b330b11a33
coded a tinydns datafile generator
Nick <nick@somerandomnick.ano>
parents:
diff
changeset
|
39 echo "&$domain:$nsip:$nsname" |
41b330b11a33
coded a tinydns datafile generator
Nick <nick@somerandomnick.ano>
parents:
diff
changeset
|
40 done |
41b330b11a33
coded a tinydns datafile generator
Nick <nick@somerandomnick.ano>
parents:
diff
changeset
|
41 done |
41b330b11a33
coded a tinydns datafile generator
Nick <nick@somerandomnick.ano>
parents:
diff
changeset
|
42 done |