build: circleci: fix GitHub API auth method (use Authorization header)

existing API will be deprecated in June/July 2020
This commit is contained in:
Christian Schwarz 2020-04-18 21:56:53 +02:00
parent 7d6ee4c166
commit c855546b9f

View File

@ -92,8 +92,9 @@ jobs:
REPO="zrepl/zrepl" REPO="zrepl/zrepl"
COMMIT="${CIRCLE_SHA1}" COMMIT="${CIRCLE_SHA1}"
JOB_NAME="${CIRCLE_JOB}" JOB_NAME="${CIRCLE_JOB}"
curl "https://api.github.com/repos/$REPO/statuses/$COMMIT?access_token=$GITHUB_COMMIT_STATUS_TOKEN" \ curl "https://api.github.com/repos/$REPO/statuses/$COMMIT" \
-H "Content-Type: application/json" \ -H "Content-Type: application/json" \
-H "Authorization: token $GITHUB_COMMIT_STATUS_TOKEN" \
-X POST \ -X POST \
-d '{"context":"zrepl/publish-ci-artifacts", "state": "success", "description":"CI Build Artifacts for '"$JOB_NAME"'", "target_url":"https://minio.cschwarz.com/minio/zrepl-ci-artifacts/'"$COMMIT"'/"}' -d '{"context":"zrepl/publish-ci-artifacts", "state": "success", "description":"CI Build Artifacts for '"$JOB_NAME"'", "target_url":"https://minio.cschwarz.com/minio/zrepl-ci-artifacts/'"$COMMIT"'/"}'