
Buy a domain, point it at your Pocketcorp, and build your website by talking to your agent on Telegram — every change live in minutes.
Your Pocketcorp has a public IP, a terminal, and an agent that writes code. That is everything a website needs. This guide wires a domain to your server, puts Caddy in front (automatic HTTPS, zero certificate work), and gives Hermes a site-builder skill with one golden rule: never claim “done” without a screenshot of the live URL.
Hermes is a terminal-native coding agent with a learning loop: after your first deploy it saves the whole build-verify-deploy workflow as a skill, so the tenth change ships faster than the first. Your Pocketcorp is the web server — the site never leaves your machine.
Create a bot with @BotFather in Telegram (30 seconds — /newbot, pick a name, copy the token). Hermes reads channel credentials from its .env:
TELEGRAM_BOT_TOKEN=123456789:AAF...
TELEGRAM_ALLOWED_USERS=987654321 # your numeric ID — ask @userinfobotRestart the gateway (hermes gateway) and say hi to your bot. Unlisted users are denied by default — the bot is yours alone.
Buy a domain anywhere (Cloudflare Registrar sells at cost), manage its DNS on Cloudflare’s free plan, and create an API token with the “Edit zone DNS” template scoped to just that zone. Give it to Hermes:
CF_API_TOKEN=v1.0-abc...
CF_ZONE_ID=023e105f4ecef8ad9ca31a8372d0c353From now on the agent manages DNS itself with one API call — this is what it runs when you say “point the domain at the server”:
curl -X POST "https://api.cloudflare.com/client/v4/zones/$CF_ZONE_ID/dns_records" \
-H "Authorization: Bearer $CF_API_TOKEN" \
-H "Content-Type: application/json" \
--data '{"type":"A","name":"mysite.com","content":"<your-pocketcorp-ip>","proxied":false}'Keep the record DNS-only (grey cloud, proxied:false) at first — Cloudflare’s proxy blocks the HTTP challenge Caddy uses to issue your HTTPS certificate. You can flip the orange cloud on after the cert exists.
Caddy turns HTTPS into a non-event: one block per domain, certificates fully automatic. Ask Hermes to install it (apt install caddy) and adopt this structure:
mysite.com {
root * /var/www/mysite.com
file_server
}
# every additional site = three more linesThe guardrail that keeps one bad edit from downing every site: the agent must always run `caddy validate --config /etc/caddy/Caddyfile` before `caddy reload`. Validate-then-reload is zero-downtime. Put this rule in the skill (next step).
This file is the difference between “an agent that can code” and “an agency that ships”. It encodes stack defaults, the deploy path, and the verification loop:
---
name: site-builder
description: Build, deploy and iterate websites on this server
---
## Defaults
- One git repo per site at ~/sites/<domain>. Every change = commit.
- Static-first: plain HTML + Tailwind (CDN) or Astro if a build
step is justified. No framework unless asked.
- Deploy = copy build output to /var/www/<domain>, then
caddy validate && caddy reload. NEVER reload without validate.
## Verify loop (non-negotiable)
- After every deploy: screenshot https://<domain> with Playwright
and send it to me with the live URL.
- If the screenshot does not match what I asked, fix and repeat
before replying. Max 3 loops, then ask.
## DNS
- New domains: create the A record via the Cloudflare API
(CF_API_TOKEN in env), verify with dig before claiming success.Now the whole workflow is conversational:
Set up mysite.com — landing page for my bakery. Warm, minimal, one page: hero, menu, opening hours, map.
Live at https://mysite.com 🍞 [screenshot] — DNS propagated, HTTPS issued by Caddy, repo initialized at ~/sites/mysite.com (commit 1a2f3c). Want changes?
Hero darker, and add a “pre-order for weekends” button.
Done — [new screenshot]. Darkened the hero overlay to 60% and added the pre-order CTA linking to your contact form. Commit 8e4d21; say “revert” to undo.
Because every iteration is a git commit, “undo yesterday’s changes” is a real command, not a hope. You can also watch edits live in the Pocketcorp VS Code tab while the agent works.
This is where Hermes differs from a one-shot site generator. After the first successful deploy, it saves what worked — your taste, the deploy quirks, the Caddy layout — via its skill_manage tool, refining the site-builder skill from experience. The second site you ask for skips every mistake the first one taught it.
Prefer not to host on your own box? The same skill works with edge hosts — swap the deploy line for `wrangler pages deploy dist/` (Cloudflare Pages, free, doesn’t even consume build minutes via direct upload) or `netlify deploy --prod`. Your Pocketcorp stays the brain; the edge serves the bytes.
A live, HTTPS-secured website on your own domain and your own server, iterated by chat, verified by screenshot, versioned in git. Changes ship in the time it takes to type them.