63fa87a replica installation: add master record only if in managed zone

1 file Authored by frenaud 5 years ago, Committed by François Cami 5 years ago,
    replica installation: add master record only if in managed zone
    
    Scenario: install a replica with DNS, whose IP address is part of a
    forward zone.
    Currently, the replica installation fails because the installer is
    trying to add a A/AAAA record for the replica in the zone
    when setting up the bind instance, and addition of records in a
    forward zone is forbidden.
    
    The bind installer should check if the IP address is in a master zone
    (i.e. a DNS zone managed by IdM, not a forward zone), and avoid
    creating the record if it's not the case.
    
    During uninstallation, perform the same check before removing the
    DNS record (if in a forward zone, no need to call dnsrecord-del).
    Fixes: https://pagure.io/freeipa/issue/7369
    Reviewed-By: Francois Cami <fcami@redhat.com>