Skip to content
Snippets Groups Projects
Commit dc69dd959c5b authored by Florent Aide's avatar Florent Aide
Browse files

upload release binary only on tag

parent 7c15f7d04e05
No related branches found
No related tags found
No related merge requests found
Pipeline #36654 passed
......@@ -56,6 +56,8 @@
key: tooling
paths:
- build
rules:
- if: '$CI_COMMIT_TAG'
script:
- |
OUTPUT_FILE=$(mktemp)
......@@ -59,7 +61,7 @@
script:
- |
OUTPUT_FILE=$(mktemp)
HTTP_CODE=$(curl --silent --output $OUTPUT_FILE --write-out "%{http_code}" --header "JOB-TOKEN: $CI_JOB_TOKEN" --upload-file build/beaver "${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/packages/generic/beaver/2.0.0/beaver")
HTTP_CODE=$(curl --silent --output $OUTPUT_FILE --write-out "%{http_code}" --header "JOB-TOKEN: $CI_JOB_TOKEN" --upload-file build/beaver "${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/packages/generic/beaver/${CI_COMMIT_TAG}/beaver")
echo "return $HTTP_CODE"
cat $OUTPUT_FILE
if [[ ${HTTP_CODE} -lt 200 || ${HTTP_CODE} -gt 299 ]] ; then
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment