Jump to content

MindAttic.Agency/ops/hetzner-bootstrap-chrome-prompt

From MindAttic Docs

Hetzner server bootstrap — Claude for Chrome prompt (MAT-T228)

Reusable prompt: paste it into Claude for Chrome, pointed at console.hetzner.cloud, already logged into the Hetzner account. Covers one new server end to end (SSH key, API token, firewall, server). Re-run it for the next server by changing the names in step 2 onward.

Before running this, generate (or reuse) a dedicated keypair on the machine running Claude Code — not something Claude for Chrome can do, since it has no filesystem access:

ssh-keygen -t ed25519 -f C:\Users\ryand\.ssh\mindattic-hetzner -N "" -C "mindattic-hetzner-<date>"

Then paste the block below into Claude for Chrome, with <PASTE PUBLIC KEY HERE> replaced by the contents of the matching .pub file.


You're in the Hetzner Cloud Console (console.hetzner.cloud), already logged in. Project: "MindAttic".
Work only inside this project. Do each step below, checking first whether it already exists before
creating it (this prompt is reused, so a repeat run should skip what's already there, not duplicate it).

1. SSH key
   Go to the MindAttic project > Security > SSH Keys.
   If a key named "mindattic-hetzner" already exists, skip this step.
   Otherwise, Add SSH Key, paste this public key, name it exactly "mindattic-hetzner":
   <PASTE PUBLIC KEY HERE>

2. API token
   Go to Security > API Tokens.
   If a token named "mindattic-agency" already exists, do NOT create another one (a token's value
   is only shown once at creation, so an existing one can't be re-read — tell me it already exists
   and skip this step).
   Otherwise: Generate API Token, name it "mindattic-agency", permission "Read & Write", Generate.
   Copy the token value the instant it's shown (it is never shown again). Report it back to me
   verbatim, on its own line, clearly labeled "API TOKEN:".

3. Firewall
   Go to Firewalls.
   If a firewall named "mindattic-main" already exists, skip creating it and just confirm its rules
   match below.
   Otherwise, Create Firewall, name it "mindattic-main", inbound rules:
     - TCP 22  from Any IPv4 and Any IPv6 (temporary — tightened to the tailnet once Tailscale is
       installed on the server; note this in your report so I remember to do that)
     - TCP 80  from Any IPv4 and Any IPv6
     - TCP 443 from Any IPv4 and Any IPv6
   Leave outbound as the default (allow all). Create it.

4. Server
   Go to Servers (inside the MindAttic project).
   If a server named "mindattic-01" already exists, skip creation — report its current public IPv4
   and server ID instead and stop here.
   Otherwise, Add Server with:
     - Location: Ashburn, US (ash)
     - Image: Ubuntu 24.04
     - Type: Shared vCPU, CPX31 (or the closest current equivalent — check the live price shown in
       the console before confirming, and tell me what it actually costs per month)
     - SSH key: mindattic-hetzner (selected in step 1)
     - Firewall: mindattic-main (selected in step 3)
     - Volumes/backups: leave off (default) unless the console warns otherwise
     - Name: mindattic-01
   Create & Buy Now.
   Wait for it to finish provisioning (status "running"), then open the server's detail page.

5. Report back, in one message, exactly:
   - API TOKEN: <value from step 2, or "already existed, not re-readable">
   - SERVER IP: <public IPv4 from the server detail page>
   - SERVER ID: <the numeric server ID from the server detail page>
   - Anything that didn't match this prompt (a renamed plan, a different region offered, an error)

After it reports back

Give the owner's reply (API token, server IP, server ID) to Claude Code in the MindAttic.Agency repo. It fills in secrets/hetzner.json (gitignored; secrets/hetzner.json.template has the shape) and takes over from there over SSH: Tailscale join, then tighten the firewall to drop the public 22/tcp rule, then SQL Server 2025 Express, the .NET runtime, Caddy, and finally deploying Gadfly (GAD-T786).

From MindAttic.Agency/docs/ops/hetzner-bootstrap-chrome-prompt.md via MindAttic.Docs; synced automatically, so edit the repo, not this page.