mirror of
https://github.com/anthropics/claude-code-action.git
synced 2026-01-22 22:44:13 +08:00
Remove all default MCP servers from agent mode
Agent mode now starts with no default servers - users must explicitly configure any MCP servers they need via mcp_config input
This commit is contained in:
@@ -112,29 +112,9 @@ ${formattedBody}`;
|
|||||||
|
|
||||||
// Agent mode: User has full control via claudeArgs
|
// Agent mode: User has full control via claudeArgs
|
||||||
// No default tools are enforced - Claude Code's defaults will apply
|
// No default tools are enforced - Claude Code's defaults will apply
|
||||||
|
// No default MCP servers - users must configure what they need
|
||||||
// Include main GitHub MCP server by default for comprehensive GitHub operations
|
|
||||||
const mcpConfig: any = {
|
const mcpConfig: any = {
|
||||||
mcpServers: {
|
mcpServers: {},
|
||||||
// Main GitHub MCP server for comprehensive GitHub operations
|
|
||||||
github: {
|
|
||||||
command: "docker",
|
|
||||||
args: [
|
|
||||||
"run",
|
|
||||||
"-i",
|
|
||||||
"--rm",
|
|
||||||
"-e",
|
|
||||||
"GITHUB_PERSONAL_ACCESS_TOKEN",
|
|
||||||
"-e",
|
|
||||||
"GITHUB_HOST",
|
|
||||||
"ghcr.io/github/github-mcp-server:sha-efef8ae", // https://github.com/github/github-mcp-server/releases/tag/v0.9.0
|
|
||||||
],
|
|
||||||
env: {
|
|
||||||
GITHUB_PERSONAL_ACCESS_TOKEN: githubToken || "",
|
|
||||||
GITHUB_HOST: GITHUB_SERVER_URL,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
};
|
};
|
||||||
|
|
||||||
// Add user-provided additional MCP config if any
|
// Add user-provided additional MCP config if any
|
||||||
|
|||||||
Reference in New Issue
Block a user