Invoke curl with --fail or --fail-with-body
Where we invoke curl
, do so with --fail
(short -f
) or with --fail-with-body
, so that failures indicated by HTTP response codes don't go undetected.
(We noticed this for a CI/CD deploy
job, which was indicating success, even though the server providing the HTTP endpoints to trigger a deployment were down.)
Edited by Raphael Das Gupta