You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Run `copilot --help` for all available flags. For the list of toolsets, see [Available toolsets](../../README.md#available-toolsets); for the list of tools, see [Tools](../../README.md#tools).
35
+
36
+
## Custom Configuration
37
+
38
+
You can configure the GitHub MCP server in Copilot CLI using either the interactive command or by manually editing the configuration file.
39
+
40
+
> **Server naming:** Name your server `github-mcp-server` to replace the built-in server, or use a different name (e.g., `github`) to run alongside it.
41
+
42
+
### Prerequisites
43
+
44
+
1.[GitHub Personal Access Token](https://github.com/settings/personal-access-tokens/new) with appropriate scopes
45
+
2. For local server: [Docker](https://www.docker.com/) installed and running
8
46
9
47
<details>
10
48
<summary><b>Storing Your PAT Securely</b></summary>
@@ -54,6 +89,8 @@ Connect to the hosted MCP server:
54
89
}
55
90
```
56
91
92
+
For additional options like toolsets and read-only mode, see the [remote server documentation](../remote-server.md#optional-headers).
93
+
57
94
#### Local Docker
58
95
59
96
With Docker running, you can run the GitHub MCP server in a container:
@@ -81,9 +118,13 @@ With Docker running, you can run the GitHub MCP server in a container:
81
118
82
119
#### Binary
83
120
84
-
You can download the latest binary release from the [GitHub releases page](https://github.com/github/github-mcp-server/releases) or build it from source by running`go build -o github-mcp-server ./cmd/github-mcp-server`.
121
+
You can download the latest binary release from the [GitHub releases page](https://github.com/github/github-mcp-server/releases) or build it from source by running:
85
122
86
-
Then, replacing `/path/to/binary` with the actual path to your binary, configure Copilot CLI with:
123
+
```bash
124
+
go build -o github-mcp-server ./cmd/github-mcp-server
125
+
```
126
+
127
+
Then configure (replace `/path/to/binary` with the actual path):
87
128
88
129
```json
89
130
{
@@ -101,35 +142,30 @@ Then, replacing `/path/to/binary` with the actual path to your binary, configure
101
142
102
143
## Verification
103
144
104
-
To verify that the GitHub MCP server has been configured:
105
-
106
-
1. Start or restart Copilot CLI
107
-
2. The GitHub tools should be available for use in your conversations
145
+
1. Restart Copilot CLI
146
+
2. Run `/mcp show` to list configured servers
147
+
3. Try: "List my GitHub repositories"
108
148
109
149
## Troubleshooting
110
150
111
151
### Local Server Issues
112
152
113
153
-**Docker errors**: Ensure Docker Desktop is running
114
-
```bash
115
-
docker --version
116
-
```
117
154
-**Image pull failures**: Try `docker logout ghcr.io` then retry
118
-
- **Docker not found**: Install Docker Desktop and ensure it's running
119
155
120
156
### Authentication Issues
121
157
122
158
-**Invalid PAT**: Verify your GitHub PAT has correct scopes:
123
-
- `repo` - Repository operations
124
-
- `read:packages` - Docker image access (if using Docker)
159
+
-`repo` - Repository operations
160
+
-`read:packages` - Docker image access (if using Docker)
0 commit comments