FEATURE: allow disabling private IPs

When forcing the internal IP to "" or "-", private IPs won't be used.
This commit is contained in:
leonnicolas
2021-02-22 20:28:16 +01:00
parent 3882d1baae
commit 9d10d4a3de
5 changed files with 49 additions and 6 deletions

View File

@@ -51,9 +51,10 @@ const (
// Node represents a node in the network.
type Node struct {
Endpoint *wireguard.Endpoint
Key []byte
InternalIP *net.IPNet
Endpoint *wireguard.Endpoint
Key []byte
NoInternalIP bool
InternalIP *net.IPNet
// LastSeen is a Unix time for the last time
// the node confirmed it was live.
LastSeen int64