Ask HN: How do you safely give LLMs SSH/DB access?

  • Thread starter Thread starter nico
  • Start date Start date
N

nico

I have been using Claude Code for DevOps style tasks like SSHing into servers, grepping logs, inspecting files, and querying databases
Overall it's been great. However, I find myself having to review every single command, a lot of which are repetitive. It still saves me a ton of time, but it's quickly becoming a bit tedious
I wish I could give the agent some more autonomy. Like giving it a list of pre-approved commands or actions that it is allowed to run over ssh
For example:

Code:
    OK: ls, grep, cat, tail
    Not OK: rm, mv, chmod, etc
    OK: SELECT queries
    Not OK: INSERT, DELETE, DROP, TRUNCATE
Has anyone successfully or satisfactorily solved this?
What setups have actually worked for you, and where do you draw the line between autonomy and risk?



Comments URL: Ask HN: How do you safely give LLMs SSH/DB access? | Hacker News

Points: 37

# Comments: 65

Continue reading...
 
Back
Top