Merge "Make DNS drivers inherit interface."
This commit is contained in:
commit
823592bc2b
@ -16,6 +16,7 @@ import ldap
|
|||||||
import time
|
import time
|
||||||
|
|
||||||
from nova import exception
|
from nova import exception
|
||||||
|
from nova.network import dns_driver
|
||||||
from nova.openstack.common import cfg
|
from nova.openstack.common import cfg
|
||||||
from nova.openstack.common import log as logging
|
from nova.openstack.common import log as logging
|
||||||
from nova import utils
|
from nova import utils
|
||||||
@ -300,7 +301,7 @@ class HostEntry(DNSEntry):
|
|||||||
parent = property(_parent)
|
parent = property(_parent)
|
||||||
|
|
||||||
|
|
||||||
class LdapDNS(object):
|
class LdapDNS(dns_driver.DNSDriver):
|
||||||
"""Driver for PowerDNS using ldap as a back end.
|
"""Driver for PowerDNS using ldap as a back end.
|
||||||
|
|
||||||
This driver assumes ldap-method=strict, with all domains
|
This driver assumes ldap-method=strict, with all domains
|
||||||
|
@ -17,14 +17,16 @@ import shutil
|
|||||||
import tempfile
|
import tempfile
|
||||||
|
|
||||||
from nova import exception
|
from nova import exception
|
||||||
|
from nova.network import dns_driver
|
||||||
from nova.openstack.common import cfg
|
from nova.openstack.common import cfg
|
||||||
from nova.openstack.common import log as logging
|
from nova.openstack.common import log as logging
|
||||||
|
|
||||||
|
|
||||||
CONF = cfg.CONF
|
CONF = cfg.CONF
|
||||||
LOG = logging.getLogger(__name__)
|
LOG = logging.getLogger(__name__)
|
||||||
|
|
||||||
|
|
||||||
class MiniDNS(object):
|
class MiniDNS(dns_driver.DNSDriver):
|
||||||
""" Trivial DNS driver. This will read/write to a local, flat file
|
""" Trivial DNS driver. This will read/write to a local, flat file
|
||||||
and have no effect on your actual DNS system. This class is
|
and have no effect on your actual DNS system. This class is
|
||||||
strictly for testing purposes, and should keep you out of dependency
|
strictly for testing purposes, and should keep you out of dependency
|
||||||
|
@ -15,7 +15,10 @@
|
|||||||
# under the License.
|
# under the License.
|
||||||
|
|
||||||
|
|
||||||
class NoopDNSDriver(object):
|
from nova.network import dns_driver
|
||||||
|
|
||||||
|
|
||||||
|
class NoopDNSDriver(dns_driver.DNSDriver):
|
||||||
""" No-op DNS manager. Does nothing. """
|
""" No-op DNS manager. Does nothing. """
|
||||||
|
|
||||||
def __init__(self):
|
def __init__(self):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user