From c2e18aaaa605e81efd5000cff84b3ccc702ad51d Mon Sep 17 00:00:00 2001 From: Trevor Batley Date: Tue, 5 Sep 2023 07:10:51 +1000 Subject: [PATCH] didn't create builder cert for local install --- koji-setup/koji-add-builder.sh | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/koji-setup/koji-add-builder.sh b/koji-setup/koji-add-builder.sh index 0c2a44d..9ab1bca 100644 --- a/koji-setup/koji-add-builder.sh +++ b/koji-setup/koji-add-builder.sh @@ -65,6 +65,14 @@ sudo -u kojiadmin koji add-host "$KOJI_BUILD_FQDN" "$RPM_ARCH" sudo -u kojiadmin koji add-host-to-channel "$KOJI_BUILD_FQDN" createrepo # A note on capacity sudo -u kojiadmin koji edit-host --capacity="$KOJID_CAPACITY" "$KOJI_BUILD_FQDN" +# Generate a certificate for the builder +if [ ! -f $SCRIPT_DIR/koji-gencert.sh ] ; then + curl $SILENT $SCRIPT_GIT/koji-gencert.sh > $SCRIPT_DIR/koji-gencert.sh +fi +cp $SCRIPT_DIR/koji-gencert.sh $KOJI_PKI_DIR/. +pushd "$KOJI_PKI_DIR" +./koji-gencert.sh "$KOJI_BUILD_FQDN" "/C=$COUNTRY_CODE/ST=$STATE/L=$LOCATION/O=$ORGANIZATION/CN=$KOJI_BUILD_FQDN" +popd # check if local install or remote if [[ $KOJI_BUILD_FQDN = $KOJI_HUB_FQDN ]] ; then # deploy locally