From 4d8034fb2eb76aa30c4ae91d10fed41a4bb1f424 Mon Sep 17 00:00:00 2001 From: xiongxz Date: Thu, 24 Sep 2026 12:05:43 +0800 Subject: [PATCH] ci: publish the hosted MCP endpoint to the MCP Registry List https://artifact-site.app.lexmount.com/mcp in the official MCP Registry as io.github.lexmount/artifact-site. Each vX.Y.Z tag publishes that version via the repository's GitHub Actions OIDC identity; workflow_dispatch covers existing tags. Co-Authored-By: Claude Opus 5.5 Signed-off-by: xiongxz --- .github/workflows/mcp-registry.yml | 40 ++++++++++++++++++++++++++++++ server.json | 18 ++++++++++++++ 2 files changed, 58 insertions(+) create mode 100644 .github/workflows/mcp-registry.yml create mode 100644 server.json diff --git a/.github/workflows/mcp-registry.yml b/.github/workflows/mcp-registry.yml new file mode 100644 index 0000000..3003797 --- /dev/null +++ b/.github/workflows/mcp-registry.yml @@ -0,0 +1,40 @@ +# Tag `vX.Y.Z` → the hosted MCP endpoint listed in the official MCP Registry +# (https://registry.modelcontextprotocol.io) as `io.github.lexmount/artifact-site`, version X.Y.Z. +# server.json at the repository root is the listing; its version is taken from package.json at +# publish time. Authentication is the GitHub Actions OIDC token of this repository, which the +# registry maps to the io.github.lexmount/* namespace, so no token is stored here. +# A version can be published once; to re-run for an existing tag, use "Run workflow" on that tag. +name: MCP Registry + +on: + push: + tags: ["v*.*.*"] + workflow_dispatch: + +permissions: + contents: read + +jobs: + publish: + name: publish to the MCP Registry + # Tags are pushed in the public repository; a matching tag in the private one must not publish. + if: github.repository == 'lexmount/artifact-site' + runs-on: ubuntu-latest + permissions: + contents: read + id-token: write # the registry verifies the OIDC token from this workflow + env: + MCP_PUBLISHER_VERSION: v1.8.1 + steps: + - uses: actions/checkout@v4 + - name: Set the listing version from package.json + run: | + version="$(jq -r .version package.json)" + jq --arg v "$version" '.version = $v' server.json > server.tmp && mv server.tmp server.json + echo "publishing version $version" + - name: Install mcp-publisher + run: | + curl -fsSL "https://github.com/modelcontextprotocol/registry/releases/download/${MCP_PUBLISHER_VERSION}/mcp-publisher_linux_amd64.tar.gz" \ + | tar -xz mcp-publisher + - run: ./mcp-publisher login github-oidc + - run: ./mcp-publisher publish diff --git a/server.json b/server.json new file mode 100644 index 0000000..6821b9b --- /dev/null +++ b/server.json @@ -0,0 +1,18 @@ +{ + "$schema": "https://static.modelcontextprotocol.io/schemas/2025-12-11/server.schema.json", + "name": "io.github.lexmount/artifact-site", + "title": "artifact-site", + "description": "One place for every AI agent's pages and docs: versioned links to share, search and update.", + "version": "0.3.0", + "websiteUrl": "https://artifact-site.app.lexmount.com", + "repository": { + "url": "https://github.com/lexmount/artifact-site", + "source": "github" + }, + "remotes": [ + { + "type": "streamable-http", + "url": "https://artifact-site.app.lexmount.com/mcp" + } + ] +}