Skip to content
22 changes: 22 additions & 0 deletions .semaphore/semaphore.yml
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,28 @@ blocks:
commands:
- git clone --branch master --single-branch [email protected]:confluentinc/connect-releases.git
- ./connect-releases/tasks/release-connect-plugins/generate-connect-changelogs.sh
- name: Connector Jar KDP Tests Gating
dependencies: []
run:
# Run this block only for pull requests
when: "pull_request =~ '.*'"
task:
jobs:
- name: Trigger and wait for Connect Jar KDP Test Task
commands:
# Don't run this block if target branch for PR is not a nightly branch or master branch
- |
if [[ "$SEMAPHORE_GIT_BRANCH" =~ ^[0-9]+\.[0-9]+\.x$ ]] || [[ "$SEMAPHORE_GIT_BRANCH" == "master" ]] ; then \
echo "PR is targeted to ${SEMAPHORE_GIT_BRANCH} branch which is feature or master branch. Triggering connector-jar-build task."; \
sem-trigger -p connect-ci-cd-pipelines \
-t run-connector-jar-tests \
-b master \
-i "REPO_NAME:$(basename $SEMAPHORE_GIT_REPO_SLUG)" \
-i "BRANCH_NAME:${SEMAPHORE_GIT_PR_BRANCH}" \
-w
else \
echo "PR is targeted to ${SEMAPHORE_GIT_BRANCH} branch which is not feature or master branch. Skipping connector-jar-build task."; \
fi;

after_pipeline:
task:
Expand Down