summaryrefslogtreecommitdiffstats
path: root/.github/workflows/cloud_regression.yml
diff options
context:
space:
mode:
Diffstat (limited to '.github/workflows/cloud_regression.yml')
-rw-r--r--.github/workflows/cloud_regression.yml53
1 files changed, 53 insertions, 0 deletions
diff --git a/.github/workflows/cloud_regression.yml b/.github/workflows/cloud_regression.yml
new file mode 100644
index 000000000..03b12c157
--- /dev/null
+++ b/.github/workflows/cloud_regression.yml
@@ -0,0 +1,53 @@
+name: Trigger Cloud Regression E2E Tests
+on:
+ push:
+ branches: [master]
+ paths:
+ - 'CMakeLists.txt'
+ - '**.c'
+ - '**.cc'
+ - '**.cpp'
+ - '**.h'
+ - 'mqtt_websockets/**'
+ - 'aclk/aclk-schemas/**'
+jobs:
+ trigger_cloud_regression_tests:
+ runs-on: ubuntu-latest
+ steps:
+ - name: Evaluate workflow dispatch parameters
+ env:
+ PR_REPO_NAME: ${{ github.event.pull_request.head.repo.full_name }}
+ PR_BRANCH_NAME: ${{ github.event.pull_request.head.ref }}
+ PR_COMMIT_HASH: ${{ github.event.pull_request.head.sha }}
+ id: output-workflow-dispatch-params
+ run: |
+ if [ ${{ github.event_name }} == 'pull_request_target' ]; then
+ NETDATA_CUSTOM_REPO="$PR_REPO_NAME"
+ NETDATA_CUSTOM_BRANCH="$PR_BRANCH_NAME"
+ NETDATA_CUSTOM_PR_NUMBER="${{ github.event.number }}"
+ NETDATA_CUSTOM_COMMIT_HASH="$PR_COMMIT_HASH"
+ elif [ ${{ github.event_name }} == 'push' ]; then
+ NETDATA_CUSTOM_REPO="netdata/netdata"
+ NETDATA_CUSTOM_BRANCH="master"
+ NETDATA_CUSTOM_PR_NUMBER=""
+ NETDATA_CUSTOM_COMMIT_HASH="${{ github.sha }}"
+ fi
+ echo "::set-output name=netdata_repo::${NETDATA_CUSTOM_REPO}"
+ echo "::set-output name=netdata_branch::${NETDATA_CUSTOM_BRANCH}"
+ echo "::set-output name=netdata_pr_number::${NETDATA_CUSTOM_PR_NUMBER}"
+ echo "::set-output name=netdata_commit_hash::${NETDATA_CUSTOM_COMMIT_HASH}"
+
+ - name: Trigger Cloud Regression
+ uses: aurelien-baudet/workflow-dispatch@v2
+ with:
+ repo: netdata/test-automation
+ ref: refs/heads/master
+ workflow: regression.yml
+ token: ${{ secrets.NETDATABOT_GITHUB_TOKEN }}
+ inputs: '{ "netdata_branch": "${{ steps.output-workflow-dispatch-params.outputs.netdata_branch }}",
+ "netdata_repo": "${{ steps.output-workflow-dispatch-params.outputs.netdata_repo }}",
+ "netdata_pr_number": "${{ steps.output-workflow-dispatch-params.outputs.netdata_pr_number }}",
+ "netdata_branch_commit_hash": "${{ steps.output-workflow-dispatch-params.outputs.netdata_commit_hash }}",
+ "custom_netdata_image": "true"
+ }'
+ wait-for-completion: false