DNS installer: accept --auto-forwarders option in unattended mode

https://fedorahosted.org/freeipa/ticket/5869

Reviewed-By: Martin Basti <mbasti@redhat.com>
This commit is contained in:
Petr Spacek
2016-05-03 14:12:44 +02:00
committed by Martin Basti
parent 7098d98100
commit e345b53f35

View File

@@ -104,8 +104,11 @@ def parse_options():
parser.error("You cannot specify a --auto-reverse option together with --no-reverse")
if options.unattended:
if not options.forwarders and not options.no_forwarders:
parser.error("You must specify at least one --forwarder option or --no-forwarders option")
if (not options.forwarders
and not options.no_forwarders
and not options.auto_forwarders):
parser.error("You must specify at least one option: "
"--forwarder or --no-forwarders or --auto-forwarders")
if options.kasp_db_file and not ipautil.file_exists(options.kasp_db_file):
parser.error("File %s does not exist" % options.kasp_db_file)