Created
May 6, 2025 07:56
-
-
Save sagara-gunathunga/4b87a5ff02f98e8982766757d4fd1cc3 to your computer and use it in GitHub Desktop.
Connecting GitHub MCP Server with MCP Inspector
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- Last updated: 6th May 2025 | |
Prerequests: | |
--------------- | |
1. GitHub PAT token | |
2. Docker runtime | |
Steps: | |
----------------- | |
1.) Create a file called config.json and save it somewhere with the following content. | |
{ | |
"mcpServers": { | |
"github": { | |
"command": "docker", | |
"args": [ | |
"run", | |
"-i", | |
"--rm", | |
"-e", | |
"GITHUB_PERSONAL_ACCESS_TOKEN", | |
"ghcr.io/github/github-mcp-server" | |
], | |
"env": { | |
"GITHUB_PERSONAL_ACCESS_TOKEN": "GitHub PAT Token" | |
} | |
} | |
} | |
} | |
2.) Replace the <PAT Token> with the token you generated. | |
3.) Run MCP Inspector with the following command. | |
npx @modelcontextprotocol/inspector --config config.json --server github | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment