Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
badra001 committed Apr 27, 2023
1 parent 5a50b95 commit dc983f2
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions code/ddns-lambda.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@
LOGGER = logging.getLogger()
account_id = None
region = None
VERSION = '1.2.0b77'
VERSION = '1.2.0b78'

# Read Env variables
DEBUG_LOG_LEVEL = os.environ.get('DebugLogLevel', 'INFO')
Expand Down Expand Up @@ -3086,7 +3086,7 @@ def process_tags_flags(tags):

def process_tags_value(name):
"""
Process the name from one of the tags and return vald (true|false), hostname, domainname, if the domainname exists in a PHZ
Process the name from one of the tags and return vald (true|false), hostname (the name if domainname is not found), domainname (if the domainname exists in a PHZ)
:param str: name (hostname or domainname) to check
:return tuple(bool,str,str): true|false if vaid, hostname, domainname
Expand All @@ -3096,12 +3096,13 @@ def process_tags_value(name):
components = parse_hostname_to_components(name)
if components:
return (True, components[0], components[1])
return (False, None, None)
return (False, name, None)


def process_tags_option_cname(tags):
"""
Process the CNAME option tag 'boc:dns:cname', determine if name and zone are valid
Process the CNAME option tag 'boc:dns:cname', determine if name and zone are valid. This allows an unqualified name (i.e, no zones)
and if a zone is not found, it will mark it as not valid, but will be used later with the tag zone or dhcp zone.
: param list(dict(string)) tags: tags from instance, list of dict of string
: return tuple(bool, str, str): true | false if vaid, hostname, domainname
Expand Down

0 comments on commit dc983f2

Please sign in to comment.