]> git.apps.os.sepia.ceph.com Git - ceph-build.git/commitdiff
ceph-dev-build: fail when the curl to shaman doesn't return a 200
authorAndrew Schoen <aschoen@redhat.com>
Thu, 4 Aug 2016 16:51:14 +0000 (11:51 -0500)
committerAndrew Schoen <aschoen@redhat.com>
Thu, 4 Aug 2016 18:38:10 +0000 (13:38 -0500)
We want to stop the build immediately if there is no healthy chacra
nodes to use.

Signed-off-by: Andrew Schoen <aschoen@redhat.com>
ceph-dev-build/build/setup

index baf92bd88f78fa6c5098d3956a39fb5ed798f6ea..8e45b26c587e3dac0f94f6b416547b2278b362db 100644 (file)
@@ -70,6 +70,6 @@ pkgs=( "chacractl>=0.0.4" )
 install_python_packages "pkgs[@]"
 
 # ask shaman which chacra instance to use
-chacra_url=`curl -u $SHAMAN_API_USER:$SHAMAN_API_KEY https://shaman.ceph.com/api/nodes/next/`
+chacra_url=`curl -f -u $SHAMAN_API_USER:$SHAMAN_API_KEY https://shaman.ceph.com/api/nodes/next/`
 # create the .chacractl config file using global variables
 make_chacractl_config $chacra_url