{"slug": "a-one-shot-prompt-for-homelabbers-who-want-a-coding-agent-to-co-operate-their", "title": "A one-shot prompt for homelabbers who want a coding agent to co-operate their gear. Adapt freely. Keep this header.", "summary": "Alan Gordie published a one-shot prompt that turns a coding agent harness such as Claude Code, Codex, or OpenCode into a \"power glove\" — a co-admin for homelab infrastructure that inventories gear read-only, proposes changes before applying them, and enforces hard stops through hooks, wrappers, or permission denylists rather than written promises. The prompt instructs the agent to use a scoped, revocable identity and to journal every session, with destructive or irreversible steps handed back to the operator. Released under Apache-2.0 in October 2026, it is designed to run on an isolated VM with network reach only to the managed gear and no outbound traffic except the model API.", "body_md": "A **power glove** is not an autopilot. It is a co-admin that sits on a control node, learns your gear, and operates it in plain language while you keep the command. It reads before it touches, proposes before it applies, and it cannot do the few things you decided it should never do. Not won't. Can't.\n\nThis prompt works with Claude Code, Codex, OpenCode, or any similar harness.\n\n1. Spin up a VM you don't mind rebuilding. Give it network reach to the gear you want operated and nothing more, and no outbound except the model API.\n2. Install your harness of choice on that VM.\n3. Start a fresh session in an **empty directory** .\n4. Fill in the `<brackets>` below and paste the whole prompt.\n5. Read what it writes down before you let it write anything else.\n\n```\nBuild me a power glove to co-operate <my hypervisor cluster / my network controller / my home automation / my docker hosts>.\n\nGround rules:\n\n1. Discover before you touch. Inventory what's reachable, what you can read, what you could change. Write it down.\n\n2. Read-only first. Earn write access one capability at a time, each one approved by me.\n\n3. Propose, then apply. Every change is a plan I can read before it's an action you take.\n\n4. Hard stops. These you never do, even if I ask in a hurry: <delete snapshots / delete VMs / change firewall rules / touch backups>. Enforce it with a hook, a wrapper, or a permission denylist, not a promise.\n\n5. Scoped identity. Your own keys, least privilege, revocable without touching mine.\n\n6. Journal every session: what you saw, what you did, what you refused, what you'd do next.\n\n7. Hand it back. If a step is destructive or irreversible, stop and give it to me.\n\nStart with rule 1. Don't ask me for credentials. Tell me what you'd need and why.\n```\n\n- **Rule 4 is the whole point.** A hook, a wrapper, or a denylist that blocks the command is a guardrail. A line in a markdown file is a suggestion. Make the agent build the block, then try to break it.\n- **Scope the identity before the first write.** A dedicated user, key, or API token for the glove. If it misbehaves, you revoke one thing and your own access is untouched.\n- **The journal is your receipt.** When something looks off a week later, you want to read what the glove saw and what it decided, in its own words.\n- **Start boring.** Read-only inventory of one system. Expand only after you've watched it behave.\n\nYour hand stays on the switch. The glove just reaches farther.\n\nv1, October 2026. Apache-2.0, Alan Gordie. Adapt freely, keep the header.", "url": "https://wpnews.pro/news/a-one-shot-prompt-for-homelabbers-who-want-a-coding-agent-to-co-operate-their", "canonical_source": "https://gist.github.com/vizionary/dc6438963417d13cadb5e96490197f26", "published_at": "2026-10-05 23:20:50+00:00", "updated_at": "2026-10-07 02:18:12.365968+00:00", "lang": "en", "topics": ["ai-agents", "ai-tools", "ai-safety", "developer-tools"], "entities": ["Alan Gordie", "Claude Code", "Codex", "OpenCode"], "also_reported_by": [], "alternates": {"html": "https://wpnews.pro/news/a-one-shot-prompt-for-homelabbers-who-want-a-coding-agent-to-co-operate-their", "markdown": "https://wpnews.pro/news/a-one-shot-prompt-for-homelabbers-who-want-a-coding-agent-to-co-operate-their.md", "text": "https://wpnews.pro/news/a-one-shot-prompt-for-homelabbers-who-want-a-coding-agent-to-co-operate-their.txt", "jsonld": "https://wpnews.pro/news/a-one-shot-prompt-for-homelabbers-who-want-a-coding-agent-to-co-operate-their.jsonld"}}