Brad suggested this change based on his commit [1]. Thank you!
[1] https://github.com/ceph/ceph-ansible/commit/
267cce9e8360fc8cb9c192fde2406e5dca724610
Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
T=$(mktemp -d)
pushd "$T"
- repo_url="https://shaman.ceph.com/api/repos/ceph/${branch}/${sha}/${env/://}/flavors/${FLAVOR}/repo"
+ distro="${env/://}"
+ api_url="https://shaman.ceph.com/api/search/?status=ready&project=ceph&flavor=${FLAVOR}&distros=${distro}/x86_64&ref=${branch}&sha1=${sha}"
+ repo_url="$(wget -O - "$api_url" | jq -r '.[0].chacra_url')repo"
+ # validate url:
+ wget -O /dev/null "$repo_url"
if grep ubuntu <<<"$env" > /dev/null 2>&1; then
# Docker makes it impossible to access anything outside the CWD : /
wget -O cephdev.asc 'https://download.ceph.com/keys/autobuild.asc'