diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-27 11:08:07 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-27 11:08:07 +0000 |
commit | c69cb8cc094cc916adbc516b09e944cd3d137c01 (patch) | |
tree | f2878ec41fb6d0e3613906c6722fc02b934eeb80 /.travis/trigger_docker_build.sh | |
parent | Initial commit. (diff) | |
download | netdata-c69cb8cc094cc916adbc516b09e944cd3d137c01.tar.xz netdata-c69cb8cc094cc916adbc516b09e944cd3d137c01.zip |
Adding upstream version 1.29.3.upstream/1.29.3upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '.travis/trigger_docker_build.sh')
-rwxr-xr-x | .travis/trigger_docker_build.sh | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/.travis/trigger_docker_build.sh b/.travis/trigger_docker_build.sh new file mode 100755 index 0000000..7a3dd50 --- /dev/null +++ b/.travis/trigger_docker_build.sh @@ -0,0 +1,19 @@ +#!/bin/sh + +token="${1}" +version="${2}" + +resp="$(curl -X POST \ + -H 'Accept: application/vnd.github.v3+json' \ + -H "Authorization: Bearer ${token}" \ + "https://api.github.com/repos/netdata/netdata/actions/workflows/docker.yml/dispatches" \ + -d "{\"ref\": \"master\", \"inputs\": {\"version\": \"${version}\"}}")" + +if [ -z "${resp}" ]; then + echo "Successfully triggered Docker image build." + exit 0 +else + echo "Failed to trigger Docker image build. Output:" + echo "${resp}" + exit 1 +fi |