Created
February 17, 2020 21:06
-
-
Save darth-veitcher/3e13d6d2c7c73d13e4ec11184114d1e2 to your computer and use it in GitHub Desktop.
Get public IP address
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
dig -4 TXT +short o-o.myaddr.l.google.com @ns1.google.com | awk -F'\"' '{ print $2}' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment