mirror of
https://github.com/mjl-/mox.git
synced 2025-07-10 06:34:40 +03:00
add config field "IPsNATed" to listener, indicating the IPs are not the actual public IPs but are NATed, to skip a few DNS checks
the dns check was returning errors that could not be fixed with that setup, which makes the checks much less useful. for issue #17
This commit is contained in:
@ -870,6 +870,10 @@ func IPs(ctx context.Context) ([]net.IP, error) {
|
||||
var ips []net.IP
|
||||
var ipv4all, ipv6all bool
|
||||
for _, l := range Conf.Static.Listeners {
|
||||
// If NATed, we don't know our external IPs.
|
||||
if l.IPsNATed {
|
||||
return nil, nil
|
||||
}
|
||||
for _, s := range l.IPs {
|
||||
ip := net.ParseIP(s)
|
||||
if ip.IsUnspecified() {
|
||||
|
Reference in New Issue
Block a user