Only set serveDns if the host is also configured to be a lighthouse. (#433)
This commit is contained in:
10
main.go
10
main.go
@ -341,7 +341,15 @@ func Main(config *Config, configTest bool, buildVersion string, logger *logrus.L
|
||||
//handshakeMACKey := config.GetString("handshake_mac.key", "")
|
||||
//handshakeAcceptedMACKeys := config.GetStringSlice("handshake_mac.accepted_keys", []string{})
|
||||
|
||||
serveDns := config.GetBool("lighthouse.serve_dns", false)
|
||||
serveDns := false
|
||||
if config.GetBool("lighthouse.serve_dns", false) {
|
||||
if config.GetBool("lighthouse.am_lighthouse", false) {
|
||||
serveDns = true
|
||||
} else {
|
||||
l.Warn("DNS server refusing to run because this host is not a lighthouse.")
|
||||
}
|
||||
}
|
||||
|
||||
checkInterval := config.GetInt("timers.connection_alive_interval", 5)
|
||||
pendingDeletionInterval := config.GetInt("timers.pending_deletion_interval", 10)
|
||||
ifConfig := &InterfaceConfig{
|
||||
|
Reference in New Issue
Block a user