summaryrefslogtreecommitdiff
path: root/oslo_config/types.py
diff options
context:
space:
mode:
authorZuul <zuul@review.opendev.org>2021-04-26 15:51:48 +0000
committerGerrit Code Review <review@openstack.org>2021-04-26 15:51:48 +0000
commit6e91dbb2d590fc1706243922c0ed71f6c2fcdf73 (patch)
treed4b066a5dcbf3b7ad9ba5525ab59fdd18cc0c54f /oslo_config/types.py
parent758775c07bc66db3ee6602ecaec53173e89c5acb (diff)
parentbb5e4cbeb973c6341bf51eea2ebe5d38366167e8 (diff)
downloadoslo-config-6e91dbb2d590fc1706243922c0ed71f6c2fcdf73.tar.gz
Merge "Adding the missing HostDomain config option"8.6.0
Diffstat (limited to 'oslo_config/types.py')
-rw-r--r--oslo_config/types.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/oslo_config/types.py b/oslo_config/types.py
index 72242cb..8ebc6e6 100644
--- a/oslo_config/types.py
+++ b/oslo_config/types.py
@@ -871,6 +871,13 @@ class HostDomain(HostAddress):
# DOMAIN_REGEX is HOSTNAME_REGEX with the _ character added
DOMAIN_REGEX = '(?!-)[A-Z0-9-_]{1,63}(?<!-)$'
+ def __init__(self, version=None, type_name='host domain value'):
+ """Check for valid version in case an IP address is provided
+
+ """
+
+ super(HostDomain, self).__init__(type_name=type_name)
+
def __call__(self, value):
"""Checks if is a valid IP/hostname.