Skip to content

Instantly share code, notes, and snippets.

@danwald
Created April 28, 2015 09:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save danwald/08b16572b66684997da0 to your computer and use it in GitHub Desktop.
Save danwald/08b16572b66684997da0 to your computer and use it in GitHub Desktop.
Get IP address of machine
ifconfig eth0 | grep inet | awk -F: '{print $2; exit}' | cut -d' ' -f1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment