From eeefccf002f3b1424b2453abf291ceb5011f98c1 Mon Sep 17 00:00:00 2001 From: Trevor Batley Date: Tue, 3 Oct 2023 09:27:31 +1100 Subject: [PATCH] remove now superfluous builder function --- install-koji-farm.sh | 43 ++----------------------------------------- 1 file changed, 2 insertions(+), 41 deletions(-) diff --git a/install-koji-farm.sh b/install-koji-farm.sh index 963844f..c55d463 100644 --- a/install-koji-farm.sh +++ b/install-koji-farm.sh @@ -215,52 +215,13 @@ EOF fi # add builders -deploy_builder () { - local FQDN=$1 - # check if server available on port 22 - until (nc -z $FQDN 22 2>/dev/null) - do - echo "I cannot connect to $FQDN! Is it online? " - echo "Options:" - echo "- FQDN= # if you've mis-typed the name" - echo "- IP= # I'll add this to your /etc/hosts file" - echo "- # try again (I've started the server)" - echo "- Q # quit this loop (give up)" - read RESPONSE - case $RESPONSE in - Q | q ) - break - ;; - null ) - continue - ;; - IP=* ) - BIP=${RESPONSE#*=} - # add this builder into the hosts file - echo "$BIP $FQDN\n" >> /etc/hosts - continue - ;; - FQDN=* ) - FQDN=${RESPONSE#*=} - continue - ;; - *) - continue - ;; - esac - done - - # we found the server and will deploy to it - koji-add-builder.sh $FQDN $DEBUG -} - if [ -z $KOJI_BUILD_FQDNS ] ; then # use hub if no builders entered - deploy_builder $KOJI_HUB_FQDN + koji-add-builder.sh $KOJI_HUB_FQDN $DEBUG else # use builders added as command line parameters for FQDN in ${KOJI_BUILD_FQDNS} ; do - deploy_builder $FQDN + koij-add-builder.sh $FQDN $DEBUG done fi