From 3f5dc26be8568564da0318205d2c15313da68e1e Mon Sep 17 00:00:00 2001 From: Jeff Volkenant Date: Fri, 21 Feb 2020 14:22:52 -0800 Subject: [PATCH] capture_stderr to prevent stderr syslog/console output from ssh-keyscan --- management/dns_update.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/management/dns_update.py b/management/dns_update.py index 7d053d5e..38336542 100755 --- a/management/dns_update.py +++ b/management/dns_update.py @@ -382,7 +382,7 @@ def build_sshfp_records(): except ValueError: pass break - keys = shell("check_output", ["ssh-keyscan", "-t", "rsa,dsa,ecdsa,ed25519", "-p", str(port), "localhost"]) + keys = shell("check_output", ["ssh-keyscan", "-t", "rsa,dsa,ecdsa,ed25519", "-p", str(port), "localhost"], capture_stderr=True) for key in sorted(keys.split("\n")): if key.strip() == "" or key[0] == "#": continue try: