Skip to content

fix(deploy): write WEBCLAW_API_KEY in generated .env#68

Merged
0xMassi merged 2 commits into
mainfrom
fix/setup-env-api-key
Jun 20, 2026
Merged

fix(deploy): write WEBCLAW_API_KEY in generated .env#68
0xMassi merged 2 commits into
mainfrom
fix/setup-env-api-key

Conversation

@0xMassi

@0xMassi 0xMassi commented Jun 20, 2026

Copy link
Copy Markdown
Owner

What

Two independent fixes split off from the e-commerce refactor branch.

1. Deploy bug — wrong env-var name in generated .env (a8eb6b3)

setup.sh and deploy/hetzner.sh wrote WEBCLAW_AUTH_KEY into the server's .env, but webclaw-server reads WEBCLAW_API_KEY (#[arg(long, env = "WEBCLAW_API_KEY")] in crates/webclaw-server/src/main.rs).

Impact:

  • The generated bearer key was silently ignored → server ran in open mode.
  • Worse on hetzner.sh: it binds 0.0.0.0, and the server refuses to bind a public interface without WEBCLAW_API_KEY (main.rs:83) → the deploy failed to start.

Fixed all four occurrences of the typo:

  • setup.sh — generated .env writer
  • deploy/hetzner.sh — cloud-init .env writer
  • deploy/hetzner.sh — help line that told users to grep WEBCLAW_AUTH_KEY
  • env.example — commented sample

Shell-local variable names ($auth_key / $AUTH_KEY) are unchanged — only the written env-var name was wrong.

2. Docs refresh — core/CLAUDE.md (e9abc8f)

Caught while verifying the above against the source tree:

  • LLM provider chain is Ollama → OpenAI → Gemini → Anthropic (Gemini was added ahead of Anthropic); docs still listed it without Gemini.
  • Documented the top-level webclaw-fetch verticals reddit.rs / linkedin.rs and the progress.rs slow-fetch emitter.
  • Extractor count ~28 → ~30, and called out the shared helpers (og.rs, github_common.rs, jsonld_product.rs, ecommerce_product.rs).

Verification

  • grep -rn WEBCLAW_AUTH_KEY → no remaining references in the repo.
  • bash -n setup.sh and bash -n deploy/hetzner.sh both pass.
  • MCP tool count cross-checked: 12 #[tool] in webclaw-mcp/src/server.rs.

🤖 Generated with Claude Code

0xMassi and others added 2 commits June 20, 2026 14:43
…H_KEY

setup.sh and deploy/hetzner.sh emitted WEBCLAW_AUTH_KEY into the server's
.env, but webclaw-server reads WEBCLAW_API_KEY (env = "WEBCLAW_API_KEY").
The generated key was silently ignored — and since hetzner.sh binds
0.0.0.0, the server refused to start at all (it rejects a public bind
without WEBCLAW_API_KEY). Fix both .env writers, plus the hetzner help
line that told users to grep the wrong name and the env.example sample.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
- LLM provider chain is Ollama -> OpenAI -> Gemini -> Anthropic; Gemini
  was added ahead of Anthropic (Google Cloud credits preferred) but the
  docs still listed Ollama -> OpenAI -> Anthropic.
- Document the top-level webclaw-fetch verticals reddit.rs / linkedin.rs
  (distinct from extractors/ and webclaw-core parsers) and progress.rs.
- Bump extractor count ~28 -> ~30 and call out the shared helpers
  (og.rs, github_common.rs, jsonld_product.rs, ecommerce_product.rs).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@0xMassi 0xMassi merged commit b7ace81 into main Jun 20, 2026
4 checks passed
@0xMassi 0xMassi deleted the fix/setup-env-api-key branch June 20, 2026 12:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant