[static-web] Let the job print the actual status code for the curl call
- From: Andrea Veri <averi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [static-web] Let the job print the actual status code for the curl call
- Date: Mon, 31 Jan 2022 19:00:02 +0000 (UTC)
commit 76dff474b752351777f7d82df0aab5b7cfc2cba5
Author: Andrea Veri <averi redhat com>
Date: Mon Jan 31 19:59:52 2022 +0100
Let the job print the actual status code for the curl call
.gitlab-ci.yml | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
---
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 834d88e..670db10 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -19,8 +19,15 @@ s3:
- |
curl --fail-with-body -o output -X POST \
-H "Authorization: Bearer ${CDN_TOKEN}" \
- "https://api.cdn77.com/v3/cdn/$CDN_RESOURCE_ID/job/purge-all"
- - cat output || true
+ "https://api.cdn77.com/v3/cdn/$CDN_RESOURCE_ID/job/purge-all" || true
+ - |
+ if "[ $? == 22 ]" ; then
+ cat output
+ exit 22
+ else
+ cat output
+ exit 0
+ fi
only:
refs:
- master
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]