Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -1011,6 +1011,17 @@ workflows:
- main
- '/release.*/'

- trigger-building-dxt:
name: Trigger building mcp-dxt (stable)
context: team-hammerhead-common-deploy-tokens
requires:
- upload npm
filters:
branches:
only:
- main
- '/release.*/'

####################################################################################################
# JOBS
####################################################################################################
Expand Down Expand Up @@ -1561,6 +1572,15 @@ jobs:
command: ./release-scripts/upload-artifacts.sh trigger-snyk-images
- failed-release-notification

trigger-building-dxt:
executor: docker-amd64
steps:
- prepare-workspace
- run:
name: Trigger build-and-release workflow at mcp-dxt
command: ./release-scripts/upload-artifacts.sh trigger_build_dxt
- failed-release-notification

noop:
executor: generic-ubuntu
steps:
Expand Down
1 change: 0 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,6 @@ $(BINARY_RELEASES_FOLDER_TS_CLI)/snyk-for-docker-desktop-darwin-arm64.tar.gz: pr
$(BINARY_RELEASES_FOLDER_TS_CLI)/docker-mac-signed-bundle.tar.gz: prepack | $(BINARY_RELEASES_FOLDER_TS_CLI)
./release-scripts/docker-desktop-release.sh
$(MAKE) $(BINARY_RELEASES_FOLDER_TS_CLI)/docker-mac-signed-bundle.tar.gz.sha256

# targets responsible for the Wrapper CLI (TS around Golang)
$(BINARY_WRAPPER_DIR)/README.md:
@cp ./README.md $(BINARY_WRAPPER_DIR)/README.md
Expand Down
30 changes: 30 additions & 0 deletions release-scripts/upload-artifacts.sh
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,32 @@ trigger_build_snyk_images() {
fi
}

trigger_build_dxt() {
echo "Triggering build-and-release workflow at mcp-dxt..."
echo "Version: $VERSION_TAG"
echo "Release Channel: $RELEASE_CHANNEL"
response_file=$TMPDIR/trigger_build_dxt.txt
RESPONSE=$(curl -L \
-X POST \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer $HAMMERHEAD_GITHUB_PAT" \
-H "X-GitHub-Api-Version: 2022-11-28" \
https://api.github.com/repos/snyk/mcp-dxt/dispatches \
-d "{\"event_type\":\"cli_release\", \"client_payload\": {\"cli_version\": \"$VERSION_TAG\"}}" \
-w "%{http_code}" \
-s \
-o "$response_file")
if [ "$RESPONSE" -eq 204 ]; then
echo "Successfully triggered build-and-release workflow at mcp-dxt."
else
echo "Failed to trigger build-and-release workflow at mcp-dxt."
echo "Response status code: $RESPONSE"
echo "Details:"
cat $response_file
exit 1
fi
}

upload_s3() {
version_target=$1
if [ "${DRY_RUN}" == true ]; then
Expand Down Expand Up @@ -222,6 +248,10 @@ for arg in "${@}"; do
elif [ "${arg}" == "trigger-snyk-images" ]; then
trigger_build_snyk_images

# Trigger building DXT in mcp-dxt repository
elif [ "${arg}" == "trigger_build_dxt" ]; then
trigger_build_dxt

# Upload files to S3 bucket
else
upload_s3 "${target}"
Expand Down