1
0
mirror of https://github.com/cmur2/dyndnsd.git synced 2025-07-12 07:11:17 +02:00

daemon: break extracting myip down into smaller parts

This commit is contained in:
cn
2018-02-02 16:14:28 +01:00
parent 6080e14356
commit 08eaacb6ab
4 changed files with 53 additions and 59 deletions

View File

@ -19,7 +19,7 @@ module Dyndnsd
out << "@ IN NS #{@dns}"
out << ""
zone['hosts'].each do |hostname,ips|
(ips.is_a?(Array) ? ips : [ips]).each do |ip|
ips.each do |ip|
ip = IPAddr.new(ip).native
type = ip.ipv6? ? "AAAA" : "A"
name = hostname.chomp('.' + @domain)