Sinatra Docs
Self-hosting

Self-hosting Sinatra

Run the OSS stack end-to-end — GitHub App, Linear App, sandboxes, env vars, docker compose, webhooks.

This guide walks you through setting up a self-hosted Sinatra instance from scratch. You'll create a GitHub App and a Linear App, choose a sandbox provider, supply LLM keys, run the stack with Docker, expose the API publicly, and wire webhooks back to it.

Plan for 30–60 minutes if you have admin access to your GitHub organization and Linear workspace and know where you'll host your public API.

The shape of the work

Steps 2–5 can be done in parallel. Steps 6–10 are sequential.

Steps in this guide

  1. Prerequisites — what you need before you start.
  2. Check out Sinatra OSS — clone, install.
  3. Create the GitHub App — App ID, Client ID, Client Secret, Webhook Secret, Private Key.
  4. Create the Linear App — Client ID, Client Secret, Webhook Secret.
  5. Choose a sandbox provider — Daytona (recommended for production) or local.
  6. Supply LLM keys — Anthropic for Claude, OpenRouter for OpenAI / Google / Meta / etc.
  7. Populate .env.production — the full env-var reference for self-host.
  8. Run with Docker Compose — Postgres, Temporal, API, worker.
  9. Expose the API publicly — domain, tunnel, or load balancer.
  10. Configure webhooks — point GitHub and Linear at your public API.
  11. Install and verify — run the install flow and check the round-trip.
  12. Troubleshooting — common failure modes and what they mean.

Where to run it

The Compose file in the repo is intended for laptop dev and small single-tenant deploys. For production multi-tenant, the maintained reference deployment uses GCP — Cloud Run for the API, GKE for the worker, Cloud SQL for Postgres, Temporal Cloud for orchestration, Cloud KMS for tenant credential encryption. Adapting to AWS / Azure / on-prem is straightforward; only the KMS provider and managed-Postgres surface change.