Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrNoIPv6Interface = fmt.Errorf("no ipv6 interfaces found")
View Source
var HttpTimeout = time.Second * 30
Functions ¶
func PublicIPv4 ¶
PublicIPv4 gets public IPv4 addr by fetching IP from an external service (ipify).
func PublicIPv6 ¶
PublicIPv6 gets public IPv6 addr, first by testing available non-loopback ipv6 interface, then by fetching IP from an external service (ipify). This is a faster (local check for fast fail) and more reliable (actual request over the internet) way of detecting ipv6
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.