Returns a character string comprising the local network IPv4 address, or vector if there are multiple addresses from multiple network adapters, or an empty character string if unavailable.

ip_addr()

Value

A named character string.

Details

The IP addresses will be named by interface (adapter friendly name on Windows) e.g. 'eth0' or 'en0'.

Examples

ip_addr()
#>         enp39s0         docker0      tailscale0 
#>   "10.2.72.104"    "172.17.0.1" "100.103.37.46"