Skip to content

Commit 47cb2db

Browse files
Merge branch 'main' into workflow-templates-server-instructions
2 parents dcba45e + 0188cc0 commit 47cb2db

23 files changed

+1087
-757
lines changed

.github/workflows/docker-publish.yml

Lines changed: 1 addition & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -127,19 +127,4 @@ jobs:
127127
# This step uses the identity token to provision an ephemeral certificate
128128
# against the sigstore community Fulcio instance.
129129
run: echo "${TAGS}" | xargs -I {} cosign sign --yes {}@${DIGEST}
130-
131-
- name: Trigger registry publication
132-
if: ${{ github.event_name != 'pull_request' && github.ref_type == 'tag' && startsWith(github.ref, 'refs/tags/v') }}
133-
uses: actions/github-script@v7
134-
with:
135-
script: |
136-
await github.rest.repos.createDispatchEvent({
137-
owner: context.repo.owner,
138-
repo: context.repo.repo,
139-
event_type: 'docker-published',
140-
client_payload: {
141-
tag: context.ref.replace('refs/tags/', ''),
142-
sha: context.sha,
143-
image_digest: '${{ steps.build-and-push.outputs.digest }}'
144-
}
145-
});
130+

.github/workflows/registry-releaser.yml

Lines changed: 8 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
name: Publish to MCP Registry
22

33
on:
4-
repository_dispatch:
5-
types: [docker-published] # Triggered after Docker image is published
4+
push:
5+
tags: ["v*"] # Triggers on version tags like v1.0.0
66
workflow_dispatch: # Allow manual triggering
77

88
jobs:
@@ -23,32 +23,28 @@ jobs:
2323

2424
- name: Fetch tags
2525
run: |
26-
if [[ "${{ github.event_name }}" == "repository_dispatch" ]]; then
27-
echo "Triggered by docker-published event for tag: ${{ github.event.client_payload.tag }}"
28-
elif [[ "${{ github.ref_type }}" != "tag" ]]; then
26+
if [[ "${{ github.ref_type }}" != "tag" ]]; then
2927
git fetch --tags
3028
else
3129
echo "Skipping tag fetch - already on tag ${{ github.ref_name }}"
3230
fi
3331
3432
- name: Wait for Docker image
3533
run: |
36-
if [[ "${{ github.event_name }}" == "repository_dispatch" ]]; then
37-
TAG="${{ github.event.client_payload.tag }}"
38-
elif [[ "${{ github.ref_type }}" == "tag" ]]; then
34+
if [[ "${{ github.ref_type }}" == "tag" ]]; then
3935
TAG="${{ github.ref_name }}"
4036
else
4137
TAG=$(git tag --sort=-version:refname | grep -E '^v[0-9]+\.[0-9]+\.[0-9]+' | head -n1)
4238
fi
4339
IMAGE="ghcr.io/github/github-mcp-server:$TAG"
4440
45-
for i in {1..6}; do
41+
for i in {1..10}; do
4642
if docker manifest inspect "$IMAGE" &>/dev/null; then
4743
echo "✅ Docker image ready: $TAG"
4844
break
4945
fi
50-
[ $i -eq 6 ] && { echo "❌ Timeout waiting for $TAG after 3 minutes"; exit 1; }
51-
echo "⏳ Waiting for Docker image ($i/6)..."
46+
[ $i -eq 10 ] && { echo "❌ Timeout waiting for $TAG after 5 minutes"; exit 1; }
47+
echo "⏳ Waiting for Docker image ($i/10)..."
5248
sleep 30
5349
done
5450
@@ -60,10 +56,7 @@ jobs:
6056
6157
- name: Update server.json version
6258
run: |
63-
if [[ "${{ github.event_name }}" == "repository_dispatch" ]]; then
64-
TAG_VERSION=$(echo "${{ github.event.client_payload.tag }}" | sed 's/^v//')
65-
echo "Using tag from dispatch: ${{ github.event.client_payload.tag }}"
66-
elif [[ "${{ github.ref_type }}" == "tag" ]]; then
59+
if [[ "${{ github.ref_type }}" == "tag" ]]; then
6760
TAG_VERSION=$(echo "${{ github.ref_name }}" | sed 's/^v//')
6861
else
6962
LATEST_TAG=$(git tag --sort=-version:refname | grep -E '^v[0-9]+\.[0-9]+\.[0-9]+(-.*)?$' | head -n 1)

README.md

Lines changed: 70 additions & 68 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,27 @@ The default configuration is:
9898

9999
See [Remote Server Documentation](docs/remote-server.md) for full details on remote server configuration, toolsets, headers, and advanced usage. This file provides comprehensive instructions and examples for connecting, customizing, and installing the remote GitHub MCP Server in VS Code and other MCP hosts.
100100

101+
#### Enterprise Cloud with data residency (ghe.com)
102+
103+
GitHub Enterprise Cloud can also make use of the remote server.
104+
105+
Example for `https://octocorp.ghe.com`:
106+
```
107+
{
108+
...
109+
"proxima-github": {
110+
"type": "http",
111+
"url": "https://copilot-api.octocorp.ghe.com/mcp",
112+
"headers": {
113+
"Authorization": "Bearer ${input:github_mcp_pat}"
114+
}
115+
},
116+
...
117+
}
118+
```
119+
120+
GitHub Enterprise Server does not support remote server hosting. Please refer to [GitHub Enterprise Server and Enterprise Cloud with data residency (ghe.com)](#github-enterprise-server-and-enterprise-cloud-with-data-residency-ghecom) from the local server configuration.
121+
101122
---
102123

103124
## Local GitHub MCP Server
@@ -160,6 +181,33 @@ To keep your GitHub PAT secure and reusable across different MCP hosts:
160181

161182
</details>
162183

184+
### GitHub Enterprise Server and Enterprise Cloud with data residency (ghe.com)
185+
186+
The flag `--gh-host` and the environment variable `GITHUB_HOST` can be used to set
187+
the hostname for GitHub Enterprise Server or GitHub Enterprise Cloud with data residency.
188+
189+
- For GitHub Enterprise Server, prefix the hostname with the `https://` URI scheme, as it otherwise defaults to `http://`, which GitHub Enterprise Server does not support.
190+
- For GitHub Enterprise Cloud with data residency, use `https://YOURSUBDOMAIN.ghe.com` as the hostname.
191+
``` json
192+
"github": {
193+
"command": "docker",
194+
"args": [
195+
"run",
196+
"-i",
197+
"--rm",
198+
"-e",
199+
"GITHUB_PERSONAL_ACCESS_TOKEN",
200+
"-e",
201+
"GITHUB_HOST",
202+
"ghcr.io/github/github-mcp-server"
203+
],
204+
"env": {
205+
"GITHUB_PERSONAL_ACCESS_TOKEN": "${input:github_token}",
206+
"GITHUB_HOST": "https://<your GHES or ghe.com domain name>"
207+
}
208+
}
209+
```
210+
163211
## Installation
164212

165213
### Install in GitHub Copilot on VS Code
@@ -668,15 +716,6 @@ The following sets of tools are available (all are on by default):
668716
- `title`: New title (string, optional)
669717
- `type`: New issue type (string, optional)
670718

671-
- **write_label** - Write operations on repository labels.
672-
- `color`: Label color as 6-character hex code without '#' prefix (e.g., 'f29513'). Required for 'create', optional for 'update'. (string, optional)
673-
- `description`: Label description text. Optional for 'create' and 'update'. (string, optional)
674-
- `method`: Operation to perform: 'create', 'update', or 'delete' (string, required)
675-
- `name`: Label name - required for all operations (string, required)
676-
- `new_name`: New name for the label (used only with 'update' method to rename) (string, optional)
677-
- `owner`: Repository owner (username or organization name) (string, required)
678-
- `repo`: Repository name (string, required)
679-
680719
</details>
681720

682721
<details>
@@ -688,12 +727,7 @@ The following sets of tools are available (all are on by default):
688727
- `owner`: Repository owner (username or organization name) (string, required)
689728
- `repo`: Repository name (string, required)
690729

691-
- **list_label** - List labels from a repository or an issue
692-
- `issue_number`: Issue number - if provided, lists labels on the specific issue (number, optional)
693-
- `owner`: Repository owner (username or organization name) - required for all operations (string, required)
694-
- `repo`: Repository name - required for all operations (string, required)
695-
696-
- **write_label** - Write operations on repository labels.
730+
- **label_write** - Write operations on repository labels.
697731
- `color`: Label color as 6-character hex code without '#' prefix (e.g., 'f29513'). Required for 'create', optional for 'update'. (string, optional)
698732
- `description`: Label description text. Optional for 'create' and 'update'. (string, optional)
699733
- `method`: Operation to perform: 'create', 'update', or 'delete' (string, required)
@@ -702,6 +736,11 @@ The following sets of tools are available (all are on by default):
702736
- `owner`: Repository owner (username or organization name) (string, required)
703737
- `repo`: Repository name (string, required)
704738

739+
- **list_label** - List labels from a repository or an issue
740+
- `issue_number`: Issue number - if provided, lists labels on the specific issue (number, optional)
741+
- `owner`: Repository owner (username or organization name) - required for all operations (string, required)
742+
- `repo`: Repository name - required for all operations (string, required)
743+
705744
</details>
706745

707746
<details>
@@ -806,6 +845,13 @@ The following sets of tools are available (all are on by default):
806845
- `per_page`: Number of results per page (max 100, default: 30) (number, optional)
807846
- `query`: Filter projects by a search query (matches title and description) (string, optional)
808847

848+
- **update_project_item** - Update project item
849+
- `item_id`: The unique identifier of the project item. This is not the issue or pull request ID. (number, required)
850+
- `owner`: If owner_type == user it is the handle for the GitHub user account. If owner_type == org it is the name of the organization. The name is not case sensitive. (string, required)
851+
- `owner_type`: Owner type (string, required)
852+
- `project_number`: The project's number. (number, required)
853+
- `updated_field`: Object consisting of the ID of the project field to update and the new value for the field. To clear the field, set "value" to null. Example: {"id": 123456, "value": "New Value"} (object, required)
854+
809855
</details>
810856

811857
<details>
@@ -824,20 +870,6 @@ The following sets of tools are available (all are on by default):
824870
- `startSide`: For multi-line comments, the starting side of the diff that the comment applies to. LEFT indicates the previous state, RIGHT indicates the new state (string, optional)
825871
- `subjectType`: The level at which the comment is targeted (string, required)
826872

827-
- **create_and_submit_pull_request_review** - Create and submit a pull request review without comments
828-
- `body`: Review comment text (string, required)
829-
- `commitID`: SHA of commit to review (string, optional)
830-
- `event`: Review action to perform (string, required)
831-
- `owner`: Repository owner (string, required)
832-
- `pullNumber`: Pull request number (number, required)
833-
- `repo`: Repository name (string, required)
834-
835-
- **create_pending_pull_request_review** - Create pending pull request review
836-
- `commitID`: SHA of commit to review (string, optional)
837-
- `owner`: Repository owner (string, required)
838-
- `pullNumber`: Pull request number (number, required)
839-
- `repo`: Repository name (string, required)
840-
841873
- **create_pull_request** - Open new pull request
842874
- `base`: Branch to merge into (string, required)
843875
- `body`: PR description (string, optional)
@@ -848,11 +880,6 @@ The following sets of tools are available (all are on by default):
848880
- `repo`: Repository name (string, required)
849881
- `title`: PR title (string, required)
850882

851-
- **delete_pending_pull_request_review** - Delete the requester's latest pending pull request review
852-
- `owner`: Repository owner (string, required)
853-
- `pullNumber`: Pull request number (number, required)
854-
- `repo`: Repository name (string, required)
855-
856883
- **list_pull_requests** - List pull requests
857884
- `base`: Filter by base branch (string, optional)
858885
- `direction`: Sort direction (string, optional)
@@ -888,6 +915,15 @@ Possible options:
888915
- `pullNumber`: Pull request number (number, required)
889916
- `repo`: Repository name (string, required)
890917

918+
- **pull_request_review_write** - Write operations (create, submit, delete) on pull request reviews.
919+
- `body`: Review comment text (string, optional)
920+
- `commitID`: SHA of commit to review (string, optional)
921+
- `event`: Review action to perform. (string, optional)
922+
- `method`: The write operation to perform on pull request review. (string, required)
923+
- `owner`: Repository owner (string, required)
924+
- `pullNumber`: Pull request number (number, required)
925+
- `repo`: Repository name (string, required)
926+
891927
- **request_copilot_review** - Request Copilot review
892928
- `owner`: Repository owner (string, required)
893929
- `pullNumber`: Pull request number (number, required)
@@ -902,13 +938,6 @@ Possible options:
902938
- `repo`: Optional repository name. If provided with owner, only pull requests for this repository are listed. (string, optional)
903939
- `sort`: Sort field by number of matches of categories, defaults to best match (string, optional)
904940

905-
- **submit_pending_pull_request_review** - Submit the requester's latest pending pull request review
906-
- `body`: The text of the review comment (string, optional)
907-
- `event`: The event to perform (string, required)
908-
- `owner`: Repository owner (string, required)
909-
- `pullNumber`: Pull request number (number, required)
910-
- `repo`: Repository name (string, required)
911-
912941
- **update_pull_request** - Edit pull request
913942
- `base`: New base branch name (string, optional)
914943
- `body`: New description (string, optional)
@@ -1200,33 +1229,6 @@ docker run -i --rm \
12001229
ghcr.io/github/github-mcp-server
12011230
```
12021231

1203-
## GitHub Enterprise Server and Enterprise Cloud with data residency (ghe.com)
1204-
1205-
The flag `--gh-host` and the environment variable `GITHUB_HOST` can be used to set
1206-
the hostname for GitHub Enterprise Server or GitHub Enterprise Cloud with data residency.
1207-
1208-
- For GitHub Enterprise Server, prefix the hostname with the `https://` URI scheme, as it otherwise defaults to `http://`, which GitHub Enterprise Server does not support.
1209-
- For GitHub Enterprise Cloud with data residency, use `https://YOURSUBDOMAIN.ghe.com` as the hostname.
1210-
``` json
1211-
"github": {
1212-
"command": "docker",
1213-
"args": [
1214-
"run",
1215-
"-i",
1216-
"--rm",
1217-
"-e",
1218-
"GITHUB_PERSONAL_ACCESS_TOKEN",
1219-
"-e",
1220-
"GITHUB_HOST",
1221-
"ghcr.io/github/github-mcp-server"
1222-
],
1223-
"env": {
1224-
"GITHUB_PERSONAL_ACCESS_TOKEN": "${input:github_token}",
1225-
"GITHUB_HOST": "https://<your GHES or ghe.com domain name>"
1226-
}
1227-
}
1228-
```
1229-
12301232
## i18n / Overriding Descriptions
12311233

12321234
The descriptions of the tools can be overridden by creating a

internal/ghmcp/server.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ func NewMCPServer(cfg MCPServerConfig) (*server.MCPServer, error) {
142142

143143
// Create default toolsets
144144
tsg := github.DefaultToolsetGroup(cfg.ReadOnly, getClient, getGQLClient, getRawClient, cfg.Translator, cfg.ContentWindowSize)
145-
err = tsg.EnableToolsets(enabledToolsets)
145+
err = tsg.EnableToolsets(enabledToolsets, nil)
146146

147147
if err != nil {
148148
return nil, fmt.Errorf("failed to enable toolsets: %w", err)

pkg/github/__toolsnaps__/create_and_submit_pull_request_review.snap

Lines changed: 0 additions & 49 deletions
This file was deleted.

pkg/github/__toolsnaps__/create_pending_pull_request_review.snap

Lines changed: 0 additions & 34 deletions
This file was deleted.

0 commit comments

Comments
 (0)