gemini-local-coder-mcp
Provides a git_status_diff tool to inspect Git working-tree status and diffs for repositories under the allowed roots.
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
gemini-local-coder-mcp
Local Streamable HTTP MCP server in TypeScript that exposes sandboxed filesystem, search, git, and shell tools to remote MCP clients (such as Google Gemini Custom Connectors) over a Cloudflare Tunnel.
Remote MCP client (e.g. Gemini Custom Connector)
-> HTTPS (OAuth 2.1 + PIN, or path-token)
-> Cloudflare Tunnel (quick tunnel or named tunnel)
-> Local server (127.0.0.1:3847, Streamable HTTP)
-> allowedRoots[]What it includes
Streamable HTTP transport built on
@modelcontextprotocol/sdk(^1.25.0) andzodLoopback-only binding (
127.0.0.1) with path and symlink checks restricted toallowedRootsAuth modes (
authMode: "oauth" | "path-token" | "both"):OAuth 2.1 + RFC 7591 Dynamic Client Registration with a local Approval PIN and
allowedRedirectHostswhitelistStatic secret URL (
/mcp/<pathToken>) for clients that do not use OAuth
Cloudflare Tunnel wrappers for local
cloudflaredand reverse-SSH relay (ssh -R)12 MCP tools:
Files:
list_roots,list_directory,read_file,write_file,edit_file,delete_file,search_filesShell & git:
run_command,git_status_diffOptional local session bridge:
antigravity_new_session,antigravity_session_status,antigravity_send_message
Related MCP server: localmcpcoder
Agent setup
To let a coding agent handle installation and config:
Fetch https://raw.githubusercontent.com/KlLLHunter/gemini-local-coder-mcp/main/docs/agent-setup.md and follow it to set up gemini-local-coder-mcp.See docs/agent-setup.md.
Manual setup
Requirements
Node.js 20+
cloudflared(locally, or on an SSH host if using reverse-SSH)Optional: a domain on Cloudflare DNS if you want a fixed URL
1. Build and configure
git clone https://github.com/KlLLHunter/gemini-local-coder-mcp.git
cd gemini-local-coder-mcp
npm install
cp config.example.json config.json
npm run build
npm testEdit config.json and list the folders the server may access in allowedRoots:
{
"host": "127.0.0.1",
"port": 3847,
"publicBaseUrl": "",
"authMode": "both",
"allowedRoots": [
"C:\\path\\to\\your\\project"
],
"tunnel": {
"mode": "local-cloudflared",
"sshHost": "my-vps",
"remoteCloudflaredPath": "$HOME/bin/cloudflared"
}
}On first start, the server writes .secrets.json (approvalPin, pathToken, and OAuth client credentials). Both config.json and .secrets.json are gitignored.
2. Expose over HTTPS
Quick tunnel (no domain)
Creates a temporary https://<random>.trycloudflare.com URL per session:
powershell -ExecutionPolicy Bypass -File .\scripts\start-with-cloudflared.ps1Named Cloudflare Tunnel (fixed domain)
In Cloudflare Zero Trust, go to Networks -> Tunnels -> Create a tunnel (
Cloudflared) and copy the tunnel token.Under Public Hostname, route a subdomain (for example
mcp.example.com) toHTTP->127.0.0.1:3847.Save the URL and token locally (stored in
config.jsonand.secrets.json; the token is passed over stdin/env, not CLI args):node dist/cli.js tunnel-configure --url=https://mcp.example.com --token="<cloudflared_token>"Start the server and tunnel:
node dist/cli.js mcp-start node dist/cli.js mcp-statusIf direct
cloudflaredconnections are blocked on your network, set"mode": "vps-cloudflared"and your SSH host alias inconfig.json, then runscripts/start-vps-tunnel.ps1ornode dist/cli.js mcp-startto forward127.0.0.1:3847viassh -R.
3. Add as a Gemini Custom Connector
Open gemini.google.com/customize/connectors (or type
@-> All Connectors -> +).Run
node dist/cli.js mcp-statusto see the active URLs and Approval PIN:For OAuth (
authMode: "oauth"or"both"): enterhttps://<your-domain>/mcpand leave Client ID / Client Secret blank (registered via RFC 7591). Confirm account linking and enter the local Approval PIN.For path-token (
authMode: "path-token"or"both"): enterhttps://<your-domain>/mcp/<pathToken>.
Save and connect.
4. CLI and Windows autostart
node dist/cli.js mcp-start [--no-tunnel] [--json]
node dist/cli.js mcp-status [--json]
node dist/cli.js mcp-stopRegister or remove Windows Task Scheduler logon startup:
powershell -ExecutionPolicy Bypass -File .\scripts\install-autostart.ps1
powershell -ExecutionPolicy Bypass -File .\scripts\uninstall-autostart.ps1Security
.secrets.json,.oauth-state.json,config.json,runtime-state.json, and*.logare excluded in.gitignore.Keep
hostset to127.0.0.1. Do not expose the port directly without HTTPS and OAuth or a path token.Review
allowedRootsandshell.enabledbefore connecting a remote client.
License
MIT
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Remote MCP server exposing your Node Command fleet (files, shell, processes, browser) to AI hosts.
Remote MCP server for supportsheep: run AI interviews and manage support content for your blog.
Remote MCP server for supportsheep: run AI interviews and manage support content for your blog.
Remote MCP server exposing SMI Aware tools, resources, and skills over Streamable HTTP.
Related MCP Servers
AlicenseNot gradedqualityDmaintenanceEnables remote MCP clients to securely access a trusted macOS machine's local file system and command execution tools (mcp-combiner) via OAuth-authenticated HTTPS through Cloudflare Tunnel, without opening router ports.MIT- AlicenseNot gradedqualityDmaintenanceEnables remote MCP clients like ChatGPT to run shell commands and manage files on your local machine via a Cloudflare tunnel, exposing tools for file operations, search, and task management.7MIT
- AlicenseNot gradedqualityBmaintenanceEnables MCP clients to securely connect to a paired Windows machine through a self-hosted Cloudflare relay and use its local filesystem and command-execution tools over Streamable HTTP and WebSocket.142 npm1MIT
- AlicenseNot gradedqualityBmaintenanceTurns your own computer into a remotely reachable MCP server so AI clients anywhere can read, write, and run commands against its files, toolchains, and local services. Includes a built-in Cloudflare tunnel, bearer-token auth, and switchable read-only, workspace, and full permission tiers with call logging.5MIT