Buzz Self Hosting logo

Buzz Self Hosting

Community
tonbistudio
buzz-self-hosting

Use when helping a user set up, debug, or operate a self-hosted Buzz relay through Docker Compose. Do not use for general Docker questions or non-Buzz Nostr deployments.

Overview

Publishertonbistudio
Repositorybuzz-skills
Skill namebuzz-self-hosting
Stars
277
Forks
18
Bundled files
1
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • 1 bundled files

    Scripts, templates, and references the model can read while it works. Files are read-only and never executed.

  • Open source

    Published by tonbistudio on GitHub. Read the source before you install it.

Installation

Install the Buzz Self Hosting AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/tonbistudio/buzz-skills/tree/main/buzz-self-hosting
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/tonbistudio/buzz-skills.git /tmp/buzz-skills
mkdir -p .claude/skills
cp -r /tmp/buzz-skills/buzz-self-hosting .claude/skills/buzz-self-hosting
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Buzz Self Hosting in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Buzz Self Hosting on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Buzz Self Hosting is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Buzz Self-Hosting Guide

Walk the user through standing up their own buzz-relay with the Docker Compose stack in deploy/compose/, and debug it layer by layer when agents or clients misbehave. Every footgun in here was hit in a real setup; check them before inventing new theories.

Guide, don't drive: give the user paste-ready commands and let them run anything that changes state. Verify results yourself with read-only checks (logs, rosters, queries).

The mental model

  • One relay = one community. The relay URL IS the community. The relay routes connections to a community by the exact hostname in BUZZ_DOMAIN. A connection with any other Host gets 404 on the WebSocket upgrade — this looks like "relay is down" but isn't.
  • The stack is: relay + Postgres (events, search, memberships) + MinIO (media + git packfiles) + Redis (pub/sub only, nothing durable) + a git volume.
  • On a closed relay (RELAY_OWNER_PUBKEY set, BUZZ_REQUIRE_RELAY_MEMBERSHIP=true), everything that connects — humans AND agents — must be in the relay member roster.

Setup steps

  1. cd deploy/compose && cp .env.example .env, then edit .env:
    • Secrets are all generated/invented locally. Nothing comes from a portal. openssl rand -hex 32 for BUZZ_RELAY_PRIVATE_KEY and BUZZ_GIT_HOOK_HMAC_SECRET; invent Postgres/Redis/S3 passwords (Compose creates those services with whatever you set).
    • RELAY_OWNER_PUBKEY = the user's own pubkey, 64-char hex, from their Buzz Desktop profile. Footgun: this var has no BUZZ_ prefix — easy to miss among neighbors that all do.
    • BUZZ_RELAY_PRIVATE_KEY is the relay's identity. Set once, never rotate; back up .env itself.
    • Pin BUZZ_IMAGE to a release tag for anything long-lived; :main moves daily.
  2. Set the URL block (BUZZ_DOMAIN, RELAY_URL, BUZZ_MEDIA_BASE_URL, BUZZ_MEDIA_SERVER_DOMAIN, BUZZ_CORS_ORIGINS) — all derive from one host choice. See the localhost footgun below before choosing.
  3. ./run.sh config (validates; catches leftover CHANGE_ME), then ./run.sh start. TLS on a public domain: BUZZ_COMPOSE_TLS=true ./run.sh start.
  4. Liveness: curl -fsS http://127.0.0.1:3000/_liveness.
  5. Register members: ./run.sh add-member <pubkey> for every human and every agent, with sleep 1 between adds (same-second roster events collide). Verify with ./run.sh list-members.
  6. Connect the desktop app with the exact RELAY_URL, create channels, add agents to channels, @mention.

Footgun: never use localhost for a local relay — use 127.0.0.1 everywhere

buzz-core::relay::normalize_relay_url rewrites every loopback host to 127.0.0.1 (localhost, ::1). The desktop app runs each managed agent's relay URL through it before spawning the harness. The relay, however, routes by the literal BUZZ_DOMAIN. Result with BUZZ_DOMAIN=localhost: the app itself connects fine (its own HTTP client doesn't rewrite the Host header) but every agent harness gets 404 and exits code 1. The app UI offers no way around it — the per-agent relay_url field is deliberately ignored (agents always inherit the active workspace relay).

Therefore: for local deployments set BUZZ_DOMAIN=127.0.0.1 and use ws://127.0.0.1:3000 in the app and everywhere else. Real public domains are unaffected.

Diagnostic — test the host routing directly (101 = good, 404 = wrong host):

bash
curl -s -o /dev/null -w "%{http_code}\n" -H "Connection: Upgrade" -H "Upgrade: websocket" \
  -H "Sec-WebSocket-Key: dGhlIHNhbXBsZSBub25jZQ==" -H "Sec-WebSocket-Version: 13" http://<host>:3000/

Footgun: changing BUZZ_DOMAIN re-keys the community

The relay ensures its deployment community keyed to the host (Deployment community ensured, host=... in relay logs). Change the domain → restart → a fresh empty community. The desktop app will keep showing the old community's channels and member lists from cache — messages even still send (kind 9) — but channel records (39000/39002, 9007/9000) don't exist relay-side, so agents discover 0 channels no matter what the UI shows.

Fix: in the app, remove the community entirely and re-add it, then create channels fresh. Verify server-side, not in the UI:

bash
docker compose --env-file .env -f compose.yml logs relay --since 10m | grep '"Event ingested via pipeline"'

Channel creation must produce kind 9007/40100 events; adding a member to a channel produces kind 9000. If the user "did it in the app" but those kinds never arrive, the app state is stale — clean re-add.

Debugging agents that don't respond — check layers in this order

Agent harness logs: %APPDATA%\xyz.block.buzz.app\agents\logs\<agent-pubkey>__<relay-hash>.log (Windows). Read the newest run — stale error banners in the app UI often describe an old failure.

Log symptomLayerFix
relay connect failed ... 404 Not Found, exit 1Hostname routing127.0.0.1 everywhere (see above)
Connects, but roster (list-members) lacks the agentRelay membership./run.sh add-member <agent-pubkey>
discovered 0 channel(s) — agent will sit idleChannel membershipAdd agent to a channel; verify a kind-9000 event lands; if UI says it's added but log still says 0 → stale community state, clean re-add
discovered 1 channel(s) + subscribed, mention ignoredrespond_toDefault is owner-only; only the owner's mentions wake it
Wakes but errors instead of replyingModel authPer-runtime credentials (Hermes setup, Claude login, OpenAI key) — plumbing is fine

Agent pubkeys and (plaintext!) private keys live in %APPDATA%\xyz.block.buzz.app\agents\managed-agents.json — treat as sensitive. The entries with private_key_nsec are the runtime records.

A healthy sequence in the harness log: connected to relay → discovered N channel(s) → subscribed to channel <uuid>; live adds show membership notification: subscribing to new channel.

Windows-specific footguns

  • ./run.sh is bash. In PowerShell it opens the file in an editor instead of running. Use Git Bash (/d/path style paths) or bash run.sh.
  • Git Bash mangles container paths: docker compose exec relay /usr/local/bin/buzz-admin ... becomes C:/Program Files/Git/usr/local/bin/... and fails with "OCI runtime exec failed". Fix: export MSYS_NO_PATHCONV=1 first, or run docker commands from PowerShell.
  • $EDITOR .env is a Unix-ism; PowerShell users should notepad .env.
  • A file named .env looks nameless in Explorer unless "File name extensions" is on.
  • If the app won't launch, check for hung instances: Get-Process buzz-desktop, buzz-acp — multiple Not-Responding buzz-desktop processes block new launches. Kill them all: Get-Process buzz-desktop, buzz-acp -ErrorAction SilentlyContinue | Stop-Process -Force.

Verification & inspection

  • Base stack exposes only relay port 3000. Admin surfaces need the dev overlay: BUZZ_COMPOSE_DEV=true ./run.sh start → MinIO console :9001 (S3 creds from .env), Adminer :8082 (server postgres, user buzz), Prometheus :9090. Home machines only — the overlay also publishes Postgres and Redis.
  • Prove data is local: docker compose --env-file .env -f compose.yml exec -T postgres psql -U buzz -d buzz -c "SELECT kind, left(content,60) FROM events WHERE kind=9 ORDER BY created_at DESC LIMIT 5;"
  • Postgres = the record (events partitioned by month, mention index, FTS, audit log, rosters). MinIO = media (content-addressed SHA-256) + git packfiles. Redis = disposable.

Backups

Volumes live inside Docker Desktop's WSL2 disk — not browsable, not backed up until dumped to real files:

powershell
copy .env <backup-dir>\env-backup.txt
docker compose --env-file .env -f compose.yml exec -T postgres pg_dump -U buzz buzz > <backup-dir>\buzz-db.sql
docker run --rm -v buzz-prod_buzz-minio-data:/data -v <backup-dir>:/backup alpine tar czf /backup/minio-data.tar.gz -C /data .
docker run --rm -v buzz-prod_buzz-git-data:/data -v <backup-dir>:/backup alpine tar czf /backup/git-data.tar.gz -C /data .

.env is part of the backup — restoring data volumes without its keys restores nothing.

Hosted → self-hosted migration

There is no export tool. Identity keypairs carry over (same person everywhere); agent definitions are local files; git repos migrate fully (clone from hosted, push to new relay). Channel history, DMs, media, canvases do not. A new relay starts empty — set expectations before the user tears anything down, and don't remove hosted communities until anything worth keeping (repos, archives via buzz messages get) is pulled.

Bundled files

The model reads these on demand while the skill is loaded. They are exposed as readable files and are never executed.

Frequently asked questions

What does the Buzz Self Hosting AI skill do?

Use when helping a user set up, debug, or operate a self-hosted Buzz relay through Docker Compose. Do not use for general Docker questions or non-Buzz Nostr deployments.

Why use Buzz Self Hosting on TypingMind?

Because you install it once and use it with any model. Buzz Self Hosting is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Buzz Self Hosting in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/tonbistudio/buzz-skills/tree/main/buzz-self-hosting. TypingMind reads its SKILL.md and bundles its files and installs it as a skill you can enable per chat.

Which AI models can use Buzz Self Hosting?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Buzz Self Hosting?

As many as you like. As long as a model supports skills, you can use Buzz Self Hosting with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Buzz Self Hosting AI skill free?

Yes. It is published on GitHub by tonbistudio under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇