From 0a4f91c84c096e0b0df2e5a1d42c38609ae7fa93 Mon Sep 17 00:00:00 2001 From: Scott Moser Date: Mon, 24 Sep 2012 14:40:41 -0400 Subject: send stderr from write-ssh-key-fingerprints to stdout This changes all output write-ssh-key-fingerprints to go to its stdout by redirecting stderr to stdout. The reason for this is that cc_keys_to_console.py was swallowing stderr and not replaying it to /dev/console. Ideally, we'd have a way in 'util.subp' to do effectively the same thing as we're doing here in the shell script. LP: #1055688 --- tools/write-ssh-key-fingerprints | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'tools') diff --git a/tools/write-ssh-key-fingerprints b/tools/write-ssh-key-fingerprints index 5723c989..130fc0c1 100755 --- a/tools/write-ssh-key-fingerprints +++ b/tools/write-ssh-key-fingerprints @@ -1,4 +1,5 @@ #!/bin/sh +exec 2>&1 fp_blist=",${1}," key_blist=",${2}," { @@ -15,8 +16,6 @@ done echo "-----END SSH HOST KEY FINGERPRINTS-----" echo "#############################################################" -} | logger -p user.info -s -t "ec2" - echo -----BEGIN SSH HOST KEY KEYS----- for f in /etc/ssh/ssh_host_*key.pub; do [ -f "$f" ] || continue @@ -26,3 +25,5 @@ for f in /etc/ssh/ssh_host_*key.pub; do cat $f done echo -----END SSH HOST KEY KEYS----- + +} | logger -p user.info --stderr -t "ec2" -- cgit v1.2.3