diff options
Diffstat (limited to 'nova/utils.py')
-rw-r--r-- | nova/utils.py | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/nova/utils.py b/nova/utils.py index 21b12aaa9..45adb7b38 100644 --- a/nova/utils.py +++ b/nova/utils.py @@ -200,19 +200,6 @@ def last_octet(address): return int(address.split(".")[-1]) -def get_my_ip(): - """Returns the actual ip of the local machine.""" - try: - csock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM) - csock.connect(('8.8.8.8', 80)) - (addr, port) = csock.getsockname() - csock.close() - return addr - except socket.gaierror as ex: - LOG.warn(_("Couldn't get IP, using 127.0.0.1 %s"), ex) - return "127.0.0.1" - - def utcnow(): """Overridable version of datetime.datetime.utcnow.""" if utcnow.override_time: |