From 5b827cb0d53d4e08785d7ebd4160c5824e6b4392 Mon Sep 17 00:00:00 2001 From: Lars Karlitski Date: Tue, 10 Nov 2020 20:39:55 +0100 Subject: [PATCH] mockbuild: change repository path Change the repository path on S3 to a more predictable one. We really only need the name of the project (static osbuild for this repository), the name of the distro (use the same as osbuild-composer's API for consistency) and the commit SHA. In particular, drop the PR number / branch name. Also don't remove the dots from version numbers. All places we're using them in (paths and URLs) support dots. For example, osbuild commit xxxxxxx for fedora-33 on x86_64 will result in this URL: osbuild/fedora-33/x86_64/xxxxxxx --- schutzbot/mockbuild.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/schutzbot/mockbuild.sh b/schutzbot/mockbuild.sh index b608e92c..70bf0f6b 100755 --- a/schutzbot/mockbuild.sh +++ b/schutzbot/mockbuild.sh @@ -49,7 +49,7 @@ MOCK_REPO_BASE_URL="http://osbuild-composer-repos.s3-website.us-east-2.amazonaws # Relative path of the repository – used for constructing both the local and # remote paths below, so that they're consistent. -REPO_PATH=${JOB_NAME}/${COMMIT}/${ID}${VERSION_ID//./}_${ARCH} +REPO_PATH=osbuild/${ID}-${VERSION_ID}/${ARCH}/${COMMIT} # Directory to hold the RPMs temporarily before we upload them. REPO_DIR=repo/${REPO_PATH} @@ -95,7 +95,7 @@ popd greenprint "📜 Generating dnf repository file" tee osbuild-mock.repo << EOF [osbuild-mock] -name=osbuild mock ${JOB_NAME}-${COMMIT} ${ID}${VERSION_ID//./} +name=osbuild mock ${COMMIT} baseurl=${REPO_URL} enabled=1 gpgcheck=0