agentleFS
lordmaculordmacu/nexo-rs/skills/ssh-exec/SKILL.md

SSH Exec

Skill8 starsChanged 7 months agoApache-2.0View on GitHub

Run shell commands on remote hosts via SSH, and transfer files via SCP. Allowlist-gated.

  • Reads credentials

The file

Files
SKILL.md

SSH Exec

Execute commands on remote Linux hosts through the system ssh client. Uses key-based auth only (BatchMode=yes — no interactive password prompts). Hosts must be explicitly allowlisted.

Use when

  • "Restart nginx on prod01"
  • "Tail /var/log/syslog on home-server"
  • Pushing / pulling a file to/from a known host
  • Kate driving ops on other machines you administer

Do not use when

  • Persistent interactive sessions — use tmux-remote
  • Containers on this host — use docker-api
  • Arbitrary / untrusted hosts — allowlist is mandatory

Tools

  • status — allowlist + bin versions
  • exec — host, command; optional timeout_secs (default 30, max 600), identity_file
  • scp_upload — host, local_path, remote_path
  • scp_download — host, remote_path, local_path

Env

VarRequiredNotes
SSH_EXEC_ALLOWED_HOSTSyescomma-separated user@host or ~/.ssh/config alias
SSH_EXEC_ALLOW_WRITESfor scp_uploadmust be "true"
SSH_EXEC_TIMEOUT_SECSnodefault 30
SSH_BIN / SCP_BINnooverride binaries

Safety

  • Non-allowlisted host → -32041 host not allowed
  • StrictHostKeyChecking=accept-new — first connect auto-adds host key; subsequent changes fail
  • BatchMode=yes — password-protected keys without agent will fail. Use ssh-agent or unencrypted deploy keys
  • Writes gated: upload requires SSH_EXEC_ALLOW_WRITES=true. Download is read-only, ungated
  • stdout truncated at 16 KB, stderr at 8 KB

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.