git » dnss » commit e0029a9

dnsserver: Log listening addresses

author Alberto Bertogli
2018-07-16 22:05:03 UTC
committer Alberto Bertogli
2018-07-16 22:05:03 UTC
parent 6b732a5e99b60231a88969cd7fc32bbd26aad3df

dnsserver: Log listening addresses

internal/dnsserver/server.go +2 -2

diff --git a/internal/dnsserver/server.go b/internal/dnsserver/server.go
index 76b2b8b..161e9d3 100644
--- a/internal/dnsserver/server.go
+++ b/internal/dnsserver/server.go
@@ -208,7 +208,7 @@ func (s *Server) systemdServe() {
 		wg.Add(1)
 		go func(c net.PacketConn) {
 			defer wg.Done()
-			log.Infof("Activate on packet connection (UDP)")
+			log.Infof("Activate on packet connection (UDP): %v", c.LocalAddr())
 			err := dns.ActivateAndServe(nil, c, dns.HandlerFunc(s.Handler))
 			log.Fatalf("Exiting UDP listener: %v", err)
 		}(pconn)
@@ -222,7 +222,7 @@ func (s *Server) systemdServe() {
 		wg.Add(1)
 		go func(l net.Listener) {
 			defer wg.Done()
-			log.Infof("Activate on listening socket (TCP)")
+			log.Infof("Activate on listening socket (TCP): %v", l.Addr())
 			err := dns.ActivateAndServe(l, nil, dns.HandlerFunc(s.Handler))
 			log.Fatalf("Exiting TCP listener: %v", err)
 		}(lis)