On 01/07/2016 09:36 AM, Milan Kubík wrote:
0029: Add 10.in-addr.arpa. zone to ipa
0030: If the IP addresses in the topology are resolvable, do not add
them to master.
Hi. I'm dropping 0029 for now. 0030 gets an update.
--
Milan Kubik
From df95013b33fa1954cc92425fb7e6ea8dc6ac7e15 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Milan=20Kub=C3=ADk?= <[email protected]>
Date: Wed, 6 Jan 2016 16:18:17 +0100
Subject: [PATCH 1/2] ipatests: Make the A record for hosts in topology
conditional
---
ipatests/test_integration/tasks.py | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/ipatests/test_integration/tasks.py b/ipatests/test_integration/tasks.py
index e7984f35fc6b3d3fec93f303b1022136c325db71..346c96ea31185251209f471d1a626b9958925698 100644
--- a/ipatests/test_integration/tasks.py
+++ b/ipatests/test_integration/tasks.py
@@ -37,7 +37,8 @@ from ipapython.ipa_log_manager import log_mgr
from ipatests.test_integration import util
from ipatests.test_integration.env_config import env_to_script
from ipatests.test_integration.host import Host
-from ipalib.util import get_reverse_zone_default
+from ipalib import errors
+from ipalib.util import get_reverse_zone_default, verify_host_resolvable
from ipalib.constants import DOMAIN_SUFFIX_NAME
from ipalib.constants import DOMAIN_LEVEL_0
@@ -892,7 +893,13 @@ def add_a_records_for_hosts_in_master_domain(master):
for host in master.domain.hosts:
# We don't need to take care of the zone creation since it is master
# domain
- add_a_record(master, host)
+ try:
+ verify_host_resolvable(host.hostname, log)
+ log.debug("The host (%s) is resolvable." % host.domain.name)
+ except errors.DNSNotARecordError:
+ log.debug("Hostname (%s) does not have A/AAAA record. Adding new one.",
+ master.hostname)
+ add_a_record(master, host)
def add_a_record(master, host):
--
2.7.0
--
Manage your subscription for the Freeipa-devel mailing list:
https://www.redhat.com/mailman/listinfo/freeipa-devel
Contribute to FreeIPA: http://www.freeipa.org/page/Contribute/Code