diff --git a/cmdeploy/src/cmdeploy/cmdeploy.py b/cmdeploy/src/cmdeploy/cmdeploy.py index e53585ac..b36b29f0 100644 --- a/cmdeploy/src/cmdeploy/cmdeploy.py +++ b/cmdeploy/src/cmdeploy/cmdeploy.py @@ -106,12 +106,6 @@ def dns_cmd_options(parser): default=None, help="write out a zonefile", ) - parser.add_argument( - "--all", - dest="all", - action="store_true", - help="check both required and recommended DNS records" - ) def dns_cmd(args, out): @@ -137,7 +131,7 @@ def dns_cmd(args, out): return 0 retcode = dns.check_full_zone( - sshexec, remote_data=remote_data, zonefile=zonefile, out=out, all=args.all + sshexec, remote_data=remote_data, zonefile=zonefile, out=out ) return retcode diff --git a/cmdeploy/src/cmdeploy/dns.py b/cmdeploy/src/cmdeploy/dns.py index 552d96ba..663ae66c 100644 --- a/cmdeploy/src/cmdeploy/dns.py +++ b/cmdeploy/src/cmdeploy/dns.py @@ -40,7 +40,7 @@ def get_filled_zone_file(remote_data): return zonefile -def check_full_zone(sshexec, remote_data, out, zonefile, all) -> int: +def check_full_zone(sshexec, remote_data, out, zonefile) -> int: """Check existing DNS records, optionally write them to zone file and return (exitcode, remote_data) tuple.""" @@ -56,12 +56,10 @@ def check_full_zone(sshexec, remote_data, out, zonefile, all) -> int: out(line) out("") returncode = 1 - if recommended_diff and (all or not required_diff): + if recommended_diff: out("WARNING: these recommended DNS entries are not set:\n") for line in recommended_diff: out(line) - if all: - returncode = 1 if not (recommended_diff or required_diff): out.green("Great! All your DNS entries are verified and correct.")