Skip to content

Add api, worker and webhook profiles to keel new - #103

Merged
ManavA merged 1 commit into
mainfrom
feat/keel-92
Sep 20, 2026
Merged

ManavA merged 1 commit into
mainfrom
feat/keel-92

Conversation

@ManavA

@ManavA ManavA commented Sep 20, 2026

Copy link
Copy Markdown
Owner

Closes #92.

Three new starting points beside minimal and standard:

  • api (examples/apionly): the notes JSON API and auth without the browser UI. No templates, static assets, or form handlers; the shared note helpers move into handlers.go. Its test pins the missing UI surface with 404s.
  • worker (examples/worker): jobs with no HTTP server. A jobs.Scheduler runs a heartbeat job that writes a worker_heartbeats row, which is the liveness signal. Own migration, own config validation.
  • webhook (examples/webhook): a minimal receiver. Verifies X-Keel-Signature over the raw bytes via webhooks.Verify, requires X-Keel-Topic and a JSON body, stores the delivery, answers 202. WEBHOOK_SECRET is required.

Each profile generates, builds, and boots against pg/testdb in cmd/keel/new_test.go (TestApiProfileBuildsAndBoots, TestWorkerProfileBuildsAndBoots, TestWebhookProfileBuildsAndBoots), and TestTemplateMatchesExample covers all five profiles. README and the tutorial profile listing updated to match keel new --help.

Evidence (KEEL_REQUIRE_DB=1):

  • go test ./cmd/keel/ — all 23 tests pass, including all five boot tests
  • go test -count=1 ./examples/apionly/ ./examples/worker/ ./examples/webhook/ — pass
  • go build ./... clean; go vet clean; golangci-lint 0 issues on changed packages
  • Mutation checks: disabling signature verification fails TestUnsignedDeliveryIsRefused; breaking the heartbeat insert fails TestHeartbeatWritesARow; both restored after

@ManavA
ManavA merged commit 505cf3f into main Sep 20, 2026
8 checks passed
@ManavA
ManavA deleted the feat/keel-92 branch September 20, 2026 16:47
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.

keel new: backend service profiles beyond notes

1 participant