How do you let ChatGPT Web inspect local code without giving it access to your whole machine?
How do you let ChatGPT Web inspect local code without giving it access to your whole machine?

How do you let ChatGPT Web inspect local code without giving it access to your whole machine?

I've been thinking about the trade-off between giving AI coding tools enough local access to be useful and giving them too much access.

For example, if I want ChatGPT Web to review my actual working tree, including uncommitted changes, the obvious options aren't great: upload files manually, push everything to GitHub, or give an agent broader access to my machine.

So I experimented with a narrower setup:

ChatGPT Web → Secure MCP Tunnel → local MCP bridge → approved repo

The bridge is read-only by default and restricted to one approved repository root. It doesn't expose shell commands, Git execution, or arbitrary filesystem access.

It also means ChatGPT can search the repository and read only relevant files rather than putting the entire codebase into context.

I'm curious how other people approach this:

How do you give AI tools useful access to local code while keeping the security boundary as small as possible? Do you prefer sandboxing, containers/VMs, read-only MCP tools, or something else?

submitted by /u/Lucaslogged
[link] [comments]