add script

This commit is contained in:
Torma Kristóf 2020-07-19 13:25:51 +02:00
parent 12706a3da2
commit 001a79de3d

19
script.sh Normal file
View File

@ -0,0 +1,19 @@
#!/usr/bin/env bash
echo 'Updating Sentry Project: '${PLUGIN_SENTRY_PROJECT}
echo 'New Release: '${DRONE_REPO}':'${DRONE_COMMIT_SHA}
curl https://sentry.kmlabz.com/api/0/organizations/kmlabz/releases/ \
-X POST \
-H 'Authorization: Bearer '${SENTRY_TOKEN} \
-H 'Content-Type: application/json' \
-d '
{
"version": "'${DRONE_BUILD_NUMBER}'",
"refs": [{
"repository":"'${DRONE_REPO}'",
"commit":"'${DRONE_COMMIT_SHA}'"
}],
"projects":["'${PLUGIN_SENTRY_PROJECT}'"]
}
'