Cairn
by WalkeU
README.md
<div align="center">
<img src="client/public/logo.svg" alt="Cairn logo" width="88" height="88">
# Cairn
**Trail markers for all your repos.**
A self-hosted ticket tracker for one person (or a small team) working across many repos, side by side with AI coding agents.
[](LICENSE)
[](docs/installation.md)
[](docs/mcp.md)
</div>
<picture>
<source media="(prefers-color-scheme: dark)" srcset="docs/images/board-dark.png">
<img alt="The Cairn board with tickets from several projects" src="docs/images/board.png">
</picture>
## Why Cairn?
When you jump between ten repos, the hard part is not the code. It is remembering where you left off. Cairn gives every repo keyed tickets, a short "where I left off" note and an activity log, all on one board. Your AI agents use the same board through MCP: they find the right project from the git remote, open a ticket before they change things, log decisions and leave a handoff note when they stop. You see everything they did, in one place.
## Features
**Tickets and board**
- Per-project keyed tickets (`SHOP-0012`), with type, priority (P1 urgent to P4 can wait, default P3), subtasks and descriptions.
- One Kanban board across all projects, with drag and drop and filters kept in the URL (`/board?p=SHOP,BLOG&prio=1,2&type=bug&q=login`).
- Columns that follow a git release flow, a separate Backlog tab, and automatic archiving of Done tickets after N days.
- A built-in general project (`GENERAL`) for work that spans several repos. Tickets can move between projects, and old keys keep working.
- Optional tags (off by default).
**Where you left off**
- A handoff note per project, written at the end of each session.
- An activity log for every ticket and project: notes, decisions, session summaries, commits and status changes.
- An overview of all projects, showing what is in progress, what is blocked and what you have not touched for a while.
**Built for agents**
- An MCP endpoint (`POST /mcp`) with 14 tools, so Claude Code, Codex and other MCP clients read and write the same board.
- Projects are identified by `git remote get-url origin`, so it works from any clone, worktree or machine.
- One API token per agent; the token name becomes the author in the log.
**Everyday use**
- English and Hungarian UI (auto-detected, switch in Settings > General > Language).
- Light and dark theme.
- Keyboard first: `C` new ticket, `Ctrl/Cmd+K` jump to any ticket or project, `/` search on the board, `Ctrl+Enter` to log.
- Built-in auth (sessions, CSRF protection, API tokens) with no third-party auth packages.
- One container, one SQLite file. Easy to back up.
<table>
<tr>
<td width="50%"><img alt="Overview of all projects with handoff notes" src="docs/images/overview.png"></td>
<td width="50%"><img alt="A ticket with its activity log" src="docs/images/ticket.png"></td>
</tr>
<tr>
<td align="center">Overview: where you left off, per project</td>
<td align="center">Ticket panel with the activity log</td>
</tr>
</table>
## Quick start
You need Docker with the Compose plugin.
```bash
git clone https://github.com/WalkeU/cairn.git
cd cairn
docker compose up -d --build
docker compose logs cairn
```
The log prints a one-time setup code. Open <http://localhost:3000>, enter the code and create your account (password: at least 12 characters).
By default Cairn listens on `127.0.0.1:3000` only. To change the address or port, copy `.env.example` to `.env` and edit it. See [Installation](docs/installation.md) for HTTPS, reverse proxies and upgrades.
## Connect your AI agent
Create an API token in **Settings > API tokens**. Cairn shows ready-to-paste setup snippets for each agent right after you create it.
<img alt="The API tokens page with setup snippets" src="docs/images/mcp-tokens.png" width="720">
**Claude Code**
```bash
claude mcp add --transport http --scope user cairn "http://localhost:3000/mcp" --header "Authorization: Bearer cairn_..."
```
**Codex** (`~/.codex/config.toml`)
```toml
[mcp_servers.cairn]
url = "http://localhost:3000/mcp"
http_headers = { Authorization = "Bearer cairn_..." }
```
The server sends its workflow rules to every agent as MCP instructions. For best results, also add a short block to your agent's global instructions. See [MCP and agents](docs/mcp.md) for the tool list, other clients and a recommended snippet.
## The board and your git flow
| Column | Meaning | Who moves it |
|---|---|---|
| Backlog | Some day, not important now (separate tab) | You |
| Todo | Committed, do this next | You, or the agent when you ask |
| Working | Being worked on | `start_ticket` |
| Blocked | Waiting on something | Anyone |
| Test | Implemented, waiting for you to check it | `complete_ticket` |
| Ready | Verified and merged into `dev`, not released yet | `complete_ticket` |
| Done | Released (or finished, in a repo without releases) | `release_tickets` after you tag a release |
| Dropped | Will not be done | Anyone |
Repos without release branches simply skip Ready and go straight to Done.
## Documentation
| Guide | What is inside |
|---|---|
| [Installation](docs/installation.md) | Docker Compose, upgrading, running from source, HTTPS and reverse proxies |
| [Configuration](docs/configuration.md) | Environment variables, `.env`, data directory, ports |
| [MCP and agents](docs/mcp.md) | Tokens, client setup, project identification, tools, recommended workflow |
| [Authentication and security](docs/auth.md) | Sessions, CSRF, API tokens, rate limits, admin CLI |
| [Backup and restore](docs/backup.md) | Backing up the SQLite database, restoring, upgrade checklist |
| [REST API](docs/api.md) | Endpoints, health check, TODO.md importer |
| [Development](docs/development.md) | Repo layout, architecture, commands, translations |
## Development
You need Node.js 22.
```bash
cd server && npm install && npm run dev # API on :3000
cd client && npm install && npm run dev # UI on :5173, proxies /api and /mcp to :3000
```
Want something to click around in? Fill an empty instance with demo projects and tickets:
```bash
CAIRN_URL=http://localhost:3000 node scripts/seed-demo.mjs # add CAIRN_TOKEN=cairn_... when auth is on
```
Before opening a pull request, run all checks from the repo root:
```bash
npm run check # server typecheck + server tests + client build
```
More in [Development](docs/development.md).
## Contributing
Contributions are welcome. Please open an issue first for bigger changes, keep pull requests small and run `npm run check` before you push. See [CONTRIBUTING.md](CONTRIBUTING.md). To report a security issue, see [SECURITY.md](SECURITY.md).
## License
[MIT](LICENSE)
This server cannot be deployed
Maintenance
ActivityMaintained
ResponsivenessNo recent community issues