From 60e1ba7c414b25995e66dd4426de60826da10b05 Mon Sep 17 00:00:00 2001 From: Holger Levsen Date: Mon, 23 Jan 2017 14:56:14 +0100 Subject: add check for controlmaster and controlpath defined in ~jenkins/.ssh/config Signed-off-by: Holger Levsen --- update_jdn.sh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'update_jdn.sh') diff --git a/update_jdn.sh b/update_jdn.sh index abbced0e..463a65a0 100755 --- a/update_jdn.sh +++ b/update_jdn.sh @@ -1,5 +1,5 @@ #!/bin/bash -# Copyright 2012-2016 Holger Levsen +# Copyright 2012-2017 Holger Levsen # released under the GPLv=2 set -e @@ -546,6 +546,12 @@ if [ "$HOSTNAME" = "jenkins" ] ; then [ -L /var/www/userContent ] || sudo ln -sf /var/lib/jenkins/userContent /var/www/userContent sudo service apache2 reload fi + if ! grep controlmaster ~jenkins/.ssh/config || ! grep controlpath ~jenkins/.ssh/config ; then + echo + echo "Please define controlmaster and controlpath in ~jenkins/.ssh/config manually, see https://debian-administration.org/article/290/Reusing_existing_OpenSSH_v4_connections" + echo + exit 1 + fi fi if [ $BASEDIR/hosts/$HOSTNAME/etc/munin -nt $STAMP ] || [ ! -f $STAMP ] ; then -- cgit v1.2.3-70-g09d2