0
0
mirror of https://github.com/thegeeklab/corenetworks.git synced 2024-11-24 20:10:40 +00:00

ensure CNAME records could not mixed with other types using the same name

This commit is contained in:
Robert Kaussow 2020-05-11 22:23:13 +02:00
parent e3dce0340f
commit a332423c45
2 changed files with 4 additions and 7 deletions

View File

@ -1,6 +1,2 @@
* ENHANCEMENT
* make `ttl` mandatory for add function
* add `requests` to requirements
* BUGFIX
* update (delete + create) records with different `ttl` to prevent duplicate entries
* add a workaround to prevent CNAME creation if a record with the same name already exists
* extend the workaround to ensure CNAME records could not mixed with other types using the same name

View File

@ -211,6 +211,7 @@ class CoreNetworks():
records = self.records(zone, params={"name": params["name"]})
for r in records:
if params["type"] == "CNAME" or r["type"] == "CNAME":
raise CorenetworksError(
"A record with the same name already exist ({name}). "
"CNAME records cannot use the same name with other records.".format(