Skip to content

Instantly share code, notes, and snippets.

@aaroncaito
Created February 17, 2017 17:19
Show Gist options
  • Save aaroncaito/1b4e4bb4c1a3da6eca1691545440896b to your computer and use it in GitHub Desktop.
Save aaroncaito/1b4e4bb4c1a3da6eca1691545440896b to your computer and use it in GitHub Desktop.
servers=( $$host1 $$host2 $$host3 )
for server in ${servers[@]}; do ip=`dig +short $server`; echo "-=# $server #=- -=@ $ip @=-"; done
pbpaste > ~/var/servers
cat ~/var/servers | grep $$public_ip
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment