Skip to content

Commit 2a5f4d4

Browse files
committed
docs(cursor): lead local install with PAT until OAuth release
Reorder install-cursor.md to show PAT Docker config first since ghcr.io/github/github-mcp-server:latest (v1.4.0) does not include stdio OAuth yet. Document :main tag for OAuth and add troubleshooting for the misleading GITHUB_PERSONAL_ACCESS_TOKEN not set error. Fixes #2779
1 parent 29634da commit 2a5f4d4

1 file changed

Lines changed: 17 additions & 12 deletions

File tree

docs/installation-guides/install-cursor.md

Lines changed: 17 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -45,13 +45,13 @@ The local GitHub MCP server runs via Docker and requires Docker Desktop to be in
4545

4646
1. Click the install button above and follow the flow, or go directly to your global MCP configuration file at `~/.cursor/mcp.json` and enter the code block below
4747
2. In Tools & Integrations > MCP tools, click the pencil icon next to "github"
48-
3. Replace `YOUR_GITHUB_PAT` with your actual [GitHub Personal Access Token](https://github.com/settings/tokens)
48+
3. Replace `YOUR_GITHUB_PAT` with your actual [GitHub Personal Access Token](https://github.com/settings/tokens) (PAT setup only; for OAuth, use the configuration below and skip this step)
4949
4. Save the file
5050
5. Restart Cursor
5151

52-
### Docker Configuration
52+
### Docker Configuration (Personal Access Token)
5353

54-
Log in with OAuth instead of a token. On github.com the official image already includes the app credentials, so you provide none yourself — the server opens a browser login on first use and keeps the token in memory only. In Docker, publish a fixed callback port to loopback:
54+
Authenticate with a Personal Access Token. This works with the current release image (`ghcr.io/github/github-mcp-server:latest`):
5555

5656
```json
5757
{
@@ -62,23 +62,23 @@ Log in with OAuth instead of a token. On github.com the official image already i
6262
"run",
6363
"-i",
6464
"--rm",
65-
"-p",
66-
"127.0.0.1:8085:8085",
6765
"-e",
68-
"GITHUB_OAUTH_CALLBACK_PORT",
66+
"GITHUB_PERSONAL_ACCESS_TOKEN",
6967
"ghcr.io/github/github-mcp-server"
7068
],
7169
"env": {
72-
"GITHUB_OAUTH_CALLBACK_PORT": "8085"
70+
"GITHUB_PERSONAL_ACCESS_TOKEN": "YOUR_GITHUB_PAT"
7371
}
7472
}
7573
}
7674
}
7775
```
7876

79-
See **[Local Server OAuth Login](../oauth-login.md)** for the native-binary flow (no fixed port), headless/device-code fallback, GitHub Enterprise, and bringing your own OAuth or GitHub App.
77+
### Docker Configuration (OAuth)
78+
79+
> **Version note**: Stdio OAuth login merged after the **v1.4.0** release (2026-06-18). Until a newer version is tagged, use the pre-release image `ghcr.io/github/github-mcp-server:main` (or build from source). The `:latest` image does **not** include OAuth yet — it exits with a misleading `GITHUB_PERSONAL_ACCESS_TOKEN not set` error instead of starting browser login. A future release will restore OAuth on `:latest`.
8080
81-
To authenticate with a Personal Access Token instead (it takes precedence over OAuth):
81+
Log in with OAuth instead of a token. On github.com the official image already includes the app credentials, so you provide none yourself — the server opens a browser login on first use and keeps the token in memory only. In Docker, publish a fixed callback port to loopback:
8282

8383
```json
8484
{
@@ -89,18 +89,22 @@ To authenticate with a Personal Access Token instead (it takes precedence over O
8989
"run",
9090
"-i",
9191
"--rm",
92+
"-p",
93+
"127.0.0.1:8085:8085",
9294
"-e",
93-
"GITHUB_PERSONAL_ACCESS_TOKEN",
94-
"ghcr.io/github/github-mcp-server"
95+
"GITHUB_OAUTH_CALLBACK_PORT",
96+
"ghcr.io/github/github-mcp-server:main"
9597
],
9698
"env": {
97-
"GITHUB_PERSONAL_ACCESS_TOKEN": "YOUR_GITHUB_PAT"
99+
"GITHUB_OAUTH_CALLBACK_PORT": "8085"
98100
}
99101
}
100102
}
101103
}
102104
```
103105

106+
See **[Local Server OAuth Login](../oauth-login.md)** for the native-binary flow (no fixed port), headless/device-code fallback, GitHub Enterprise, and bringing your own OAuth or GitHub App.
107+
104108
> **Important**: The npm package `@modelcontextprotocol/server-github` is no longer supported as of April 2025. Use the official Docker image `ghcr.io/github/github-mcp-server` instead.
105109
106110
## Configuration Files
@@ -128,6 +132,7 @@ To authenticate with a Personal Access Token instead (it takes precedence over O
128132
- **Docker errors**: Ensure Docker Desktop is running
129133
- **Image pull failures**: Try `docker logout ghcr.io` then retry
130134
- **Docker not found**: Install Docker Desktop and ensure it's running
135+
- **`GITHUB_PERSONAL_ACCESS_TOKEN not set` with OAuth config**: The published `:latest` image (v1.4.0) does not include stdio OAuth. Use the PAT configuration above, or switch the image tag to `ghcr.io/github/github-mcp-server:main` until the next release
131136

132137
### General Issues
133138

0 commit comments

Comments
 (0)