osmith has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ci/+/40331?usp=email )
Change subject: OBS: gerrit_binpkgs: add FEED parameter ......................................................................
OBS: gerrit_binpkgs: add FEED parameter
Allow switching to another feed easily. I'm using this to build packages for ubuntu quickly, for which we don't have a master feed (only for debian 10, 11, 12 currently).
Change-Id: I1b04694e475a74b130ab3f801b99a0e827519ff8 --- M scripts/obs/gerrit_binpkgs.sh 1 file changed, 9 insertions(+), 1 deletion(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-ci refs/changes/31/40331/1
diff --git a/scripts/obs/gerrit_binpkgs.sh b/scripts/obs/gerrit_binpkgs.sh index f199844..34f90c4 100755 --- a/scripts/obs/gerrit_binpkgs.sh +++ b/scripts/obs/gerrit_binpkgs.sh @@ -1,6 +1,7 @@ #!/bin/sh -e SCRIPTS_OBS_DIR="$(realpath "$(dirname "$0")")" DISTRO="$1" +FEED=${2:-master}
error_exit() { echo "---" @@ -12,9 +13,13 @@
if [ -z "$DISTRO" ]; then - echo "usage: gerrit-binpkgs.sh DISTRO" + echo "usage: gerrit-binpkgs.sh DISTRO [FEED]" + echo + echo "FEED defaults to master." + echo echo "examples:" echo " gerrit-binpkgs.sh debian:12" + echo " gerrit-binpkgs.sh ubuntu:24.04 nightly" echo " gerrit-binpkgs.sh almalinux:8" exit 1 fi @@ -35,6 +40,8 @@ mkdir -p "$CACHE_DIR" rsync -a --delete "$GIT_REPO_DIR" "$CACHE_DIR"
+# --feed must be master here, as for build_srcpkg it means that we take the +# currently checked out commit and add a commit_….txt file. echo ":: Building the source package" "$SCRIPTS_OBS_DIR"/build_srcpkg.py \ --allow-unknown-package \ @@ -48,6 +55,7 @@ echo ":: Building the binary packages" "$SCRIPTS_OBS_DIR"/build_binpkg.py \ --docker "$DISTRO" \ + --feed "$FEED" \ "$PROJECT_NAME" || error_exit
echo ":: Find binary packages in: $SCRIPTS_OBS_DIR/_temp/binpkgs"