I have Claude Code and I’d like to make the best use possible of it to assist me in setting up and managing my install. I do not want to give it any kind of write access. Is there a way to give it SSH access to my Discourse install with only read permissions? Same with the database? And to forbid access to anything “security/confidential” on the server? Seems to me it would be much more efficient if I can give it this kind of access, rather than have it read web pages, dig through SQL dumps (btw, come to think of it: do those contain anything sensitive security-wise? I imagine they do), give it screenshots or copy-paste settings and error messages…
Yes, you can create an SSH user that has read-only access and let Claude Code use that… this protects from unauthorized changes, but it will still be able to read sensitive information.
Your imagination is correct! the content of personal messages, hashed passwords, IP addresses, API keys, etc… lots of things.
It’s easier to create a duplicate site without sensitive data with the same configuration and use that as a sandbox. There are tradeoffs because you’d have to maintain a separate site and keep the configuration synced, and sometimes you might only be able to reproduce an issue in production, but it’s the safest way.
You’re right to be cautious… our own security policy on the Discourse team restricts this for us too, we can’t let an LLM access production databases.