Skip to content

Conversation

@himanshusinghs
Copy link
Collaborator

@himanshusinghs himanshusinghs commented Dec 8, 2025

Proposed changes

Our publish job which publishes the artifacts to MCP registry depends on the docker image being available already but its not when we publish. The docker images are published on a scheduled basis or on manual dispatch.

This PR changes the publish workflow such that we publish to docker as soon as we have the npm package listed in the registry and then proceed ahead with MCP registry publish.

An example failure - https://github.com/mongodb-js/mongodb-mcp-server/actions/runs/19944234451/job/57189691853

Checklist

@coveralls
Copy link
Collaborator

coveralls commented Dec 8, 2025

Pull Request Test Coverage Report for Build 20130693737

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.004%) to 80.03%

Totals Coverage Status
Change from base Build 20130488921: 0.004%
Covered Lines: 6631
Relevant Lines: 8204

💛 - Coveralls

@himanshusinghs himanshusinghs marked this pull request as ready for review December 8, 2025 13:16
@himanshusinghs himanshusinghs requested a review from a team as a code owner December 8, 2025 13:16
Copilot AI review requested due to automatic review settings December 8, 2025 13:16
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes the publish workflow to ensure Docker images are available before publishing to the MCP registry. Previously, the MCP registry publish job depended on Docker images that were only built on a schedule or manual dispatch, causing failures during releases.

Key changes:

  • Refactored Docker build/push logic into a reusable workflow action
  • Added npm package availability check before Docker publishing in the main publish workflow
  • Updated dependency chain: publish → wait for npm → docker-push → mcp-publish

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.

File Description
.github/workflows/publish.yml Added npm package availability polling, docker-push job dependency, and renamed mcp-publish job with correct dependencies
.github/workflows/docker.yml Refactored to use new reusable docker-publish action and improved failure handling job
.github/actions/docker-publish.yml New reusable workflow containing extracted Docker build and push logic

@@ -0,0 +1,50 @@
---
name: Build and Push Docker Image
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

q: should this be a workflow or an action? tbh not sure what pros and cons of each are

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

They both could be used for reusability. I used the workflow here only because they have better support for credentials masking. I don't have a strong feeling about it though as I only recently found about this and was curious to see this in action.

@himanshusinghs himanshusinghs force-pushed the chore/fix-publish-workflow branch from e2dbdae to f607e46 Compare December 11, 2025 10:54
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.

name: Publish to MCP Registry
on:
workflow_call:
workflow_dispatch:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: I think you only need this on the other one

Suggested change
workflow_dispatch:

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This in intentional because we still want to be able to publish to MCP registry manually in case the relevant parts in publish job fails.

Also relevant for the current v1.3.0 release which was never published in MCP registry so this is expected to help with that as well.

Copy link
Collaborator

@cveticm cveticm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@himanshusinghs himanshusinghs merged commit 0e1acff into main Dec 11, 2025
18 checks passed
@himanshusinghs himanshusinghs deleted the chore/fix-publish-workflow branch December 11, 2025 15:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants