pip install netifaces
netifaces.ifaddresses(netifaces.gateways()['default'][netifaces.AF_INET][1])[netifaces.AF_LINK][0]['addr']
Last active
August 1, 2019 07:41
-
-
Save risha700/adbc3935975f815bcb2d89177ef685e4 to your computer and use it in GitHub Desktop.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment