summaryrefslogtreecommitdiffstats
path: root/.travis.yml
diff options
context:
space:
mode:
authorAustin S. Hemmelgarn <austin@netdata.cloud>2021-01-22 09:22:22 -0500
committerGitHub <noreply@github.com>2021-01-22 09:22:22 -0500
commitd0a54068a3ba00bcd7b29433dee8894cabf17fa3 (patch)
treee50d72afa1b940a6b3fd1155b6d91166d4905f0b /.travis.yml
parent8ea80fbd465a3bdc0a35faaaf1385039ec6031bb (diff)
Properly handle arguments and responses for triggering Docker builds. (#10545)
This moves the actual cURL command to a script, which both properly handles the required parameters and also checks the results of the call so that it throws an error if triggering the Docker build fails.
Diffstat (limited to '.travis.yml')
-rw-r--r--.travis.yml14
1 files changed, 2 insertions, 12 deletions
diff --git a/.travis.yml b/.travis.yml
index 1d80e943bc..8a639fd38e 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -361,12 +361,7 @@ jobs:
after_failure: post_message "TRAVIS_MESSAGE" "<!here> Draft release submission failed"
- name: Trigger Docker image build and publish
- script: >-
- curl -X POST \
- -H 'Accept: application/vnd.github.v3+json' \
- -H "Authorization: Bearer ${GITHUB_TOKEN}" \
- 'https://api.github.com/repos/netdata/netdata/actions/workflows/docker.yml/dispatches' \
- -d '{"ref": "master", "inputs": {"version": "${build_version}"}}'
+ script: .travis/trigger_docker_build.sh "${GITHUB_TOKEN}" "${BUILD_VERSION}"
after_failure: post_message "TRAVIS_MESSAGE" "<!here> Failed to trigger docker build during release" "${NOTIF_CHANNEL}"
- stage: Trigger deb and rpm package build (release)
@@ -462,12 +457,7 @@ jobs:
after_deploy: rm -f .travis/gcs-credentials.json
- name: Trigger Docker image build and publish
- script: >-
- curl -X POST \
- -H 'Accept: application/vnd.github.v3+json' \
- -H "Authorization: Bearer ${GITHUB_TOKEN}" \
- 'https://api.github.com/repos/netdata/netdata/actions/workflows/docker.yml/dispatches' \
- -d '{"ref": "master", "inputs": {"version": "${build_version}"}}'
+ script: .travis/trigger_docker_build.sh "${GITHUB_TOKEN}" "${BUILD_VERSION}"
after_failure: post_message "TRAVIS_MESSAGE" "<!here> Failed to trigger docker build during nightly release" "${NOTIF_CHANNEL}"
- stage: Trigger deb and rpm package build (nightly release)