added missing isotime method from utils
This commit is contained in:
parent
2c69755f05
commit
c2657e705b
@ -22,13 +22,14 @@
|
||||
System-level utilities and helper functions.
|
||||
"""
|
||||
|
||||
import logging
|
||||
import socket
|
||||
import sys
|
||||
import os.path
|
||||
import datetime
|
||||
import inspect
|
||||
import subprocess
|
||||
import logging
|
||||
import os.path
|
||||
import random
|
||||
import socket
|
||||
import subprocess
|
||||
import sys
|
||||
|
||||
from nova import flags
|
||||
|
||||
@ -114,3 +115,8 @@ def get_my_ip():
|
||||
(addr, port) = csock.getsockname()
|
||||
csock.close()
|
||||
return addr
|
||||
|
||||
def isotime(at=None):
|
||||
if not at:
|
||||
at = datetime.utcnow()
|
||||
return at.strftime("%Y-%m-%dT%H:%M:%SZ")
|
||||
|
Loading…
x
Reference in New Issue
Block a user