]> git.apps.os.sepia.ceph.com Git - ceph-build.git/commit
ceph-dev*build: Wait for the appropriate arch's repo to be ready 1918/head
authorDavid Galloway <dgallowa@redhat.com>
Fri, 1 Oct 2021 15:07:40 +0000 (11:07 -0400)
committerDavid Galloway <dgallowa@redhat.com>
Wed, 6 Oct 2021 13:21:58 +0000 (09:21 -0400)
commit1ee2f6796c2c7fe2f79c73e11f9c0e606d451a76
tree75329a68e770608fca5cd489f9ee3dc697edbcf2
parent028e439805cad7e52e896eb886ff0e893ffb9c19
ceph-dev*build: Wait for the appropriate arch's repo to be ready

Also use shaman's search API.

What was happening before this was, for example:

- master branch gets built
- x86_64 job, build, and repo are done way before arm64
- arm64 job finally gets to the point where it's ready to build its container
- arm64 job checks with shaman to ask if the branch's repo is ready
- shaman answers with the x86_64 repo status and says it is ready
- arm64 job proceeds but fails because the arm64 repo is not ready

```
$ echo $RELEASE
8
$ echo $SHA1
d5759e030bea9732b905c51d041fe16c934790ce
$ echo $BRANCH
master
$ echo $FLAVOR
default
$ for ARCH in x86_64 arm64; do echo "============== $ARCH =============="; curl -s "https://shaman.ceph.com/api/search/?project=ceph&distros=centos/${RELEASE}/${ARCH}&sha1=${SHA1}&ref=${BRANCH}&flavor=${FLAVOR}" | jq -r '.[0].status'; done
============== x86_64 ==============
ready
============== arm64 ==============
ready

```

Signed-off-by: David Galloway <dgallowa@redhat.com>
ceph-dev-build/build/build_rpm
ceph-dev-new-build/build/build_rpm