Commit graph

19 commits

Author SHA1 Message Date
Christian Hesse
9bfa303038 dhcp-to-dns: use 'active-' properties from lease
Turns out that address for static leases can be an address pool. Of
course that breaks the script as an ip address is expected. Use
'active-address'  instead.

Also let's do the same for 'active-mac-address'...

Fixes GH-43
2023-06-08 21:58:29 +02:00
Christian Hesse
ee94024dca dhcp-to-dns: get domain from dhcp server's network definition 2023-04-24 22:26:26 +02:00
Christian Hesse
ac5d84173f dhcp-to-dns: rename variable to not clash with global one 2023-04-24 22:26:26 +02:00
Christian Hesse
79cdefbd1e dhcp-to-dns: handle change of domain 2023-04-24 22:26:26 +02:00
Christian Hesse
517bb4ede8 dhcp-to-dns: get all values of dns record 2023-04-24 22:26:26 +02:00
Christian Hesse
4c416cb39e dhcp-to-dns: handle duplicate leases earlier 2023-04-24 22:26:26 +02:00
Christian Hesse
f3876b0637 dhcp-to-dns: handle dns record by comment and type 2023-04-24 22:26:26 +02:00
Christian Hesse
779b3b8872 dhcp-to-dns: use better condition
The condition worked, but could match others (AAAA, NXDOMAIN, ...) as
well (though these should not exist).

The problem is that matching with `type=A` does not return any results.
For historical reasons A records have no type, thus can be matched with
`!type`. I opened an issue to fix this... (SUP-111312)

So let's assum `!type` works and `type=A` could become valid...
2023-03-29 15:49:41 +02:00
Christian Hesse
d700dbc00e dhcp-to-dns: support host name from dhcp lease comment
The lease comment is supposed to be a human readable string... But we
could allow parsable information.
2023-03-28 12:05:47 +02:00
Christian Hesse
40f0d54ea8 dhcp-to-dns: add cname if host name appears for existing record 2023-03-28 11:42:58 +02:00
Christian Hesse
295ccb570d dhcp-to-dns: update cname record on changed host name 2023-03-22 21:53:32 +01:00
Christian Hesse
b13a53531b dhcp-to-dns: just update the address
The other values *should* be unchanged...
2023-03-22 21:53:32 +01:00
Christian Hesse
c5c235246b dhcp-to-dns: add debug message on duplicate leases 2023-03-22 21:53:32 +01:00
Christian Hesse
8c728bb6ab dhcp-to-dns: do not update records based on host name 2023-03-22 21:53:32 +01:00
Christian Hesse
aac8709881 dhcp-to-dns: always create A record with mac address...
... and an optional CNAME with host name.
2023-03-22 21:53:32 +01:00
Christian Hesse
4a0f395fe1 dhcp-to-dns: split fqdn to host name and domain 2023-03-22 10:42:41 +01:00
Christian Hesse
682a09c94b dhcp-to-dns: match comment on beginning of line 2023-03-22 10:13:24 +01:00
Christian Hesse
3d589def7d dhcp-to-dns: allow the matching separator string in name 2023-03-22 10:13:24 +01:00
Christian Hesse
a832fd04ef rename scripts and add file extension ".rsc"
No functional change for the user... The migration is done
automatically.
2023-03-07 22:26:01 +01:00