my machine ip address linux code example
Example 1: get your ip address from terminal
for local ip :
hostname -I
for Public ip :
curl icanhazip.com
Example 2: how to see ip in linux
curl ifconfig.me
for local ip :
hostname -I
for Public ip :
curl icanhazip.com
curl ifconfig.me