Move domain config from .env to a private SQLite store

Forges (multi-host) + tokens, project directories, and git identity now live in a private SQLite config store (internal/store, modernc.org/sqlite) on a /data named volume that is not bind-mounted or exposed, so credentials aren't reachable outside the container. New Settings page (/settings) + <settings-panel> with /api/config CRUD. Scanner reads roots fresh from the store each cycle; service resolves forges per-repo from the store and reapplies per-forge git auth on change. First run seeds the store from .env. Overturns the old no-datastore/.env-config laws (AGENT.md updated). Verified live end-to-end.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
2026-09-22 05:31:28 -04:00
parent 69d38484e8
commit e30c3b632a
18 changed files with 1208 additions and 160 deletions
+15
View File
@@ -53,6 +53,21 @@
<li><strong>Ahead / behind</strong> — commits your branch leads or trails its upstream by.</li>
</ul>
<h2>Settings</h2>
<p>
Open <a href="/settings">Settings</a> to manage your configuration (it's
stored in a private database inside the app, not in files):
</p>
<ul>
<li><strong>Forges</strong> — add your Git hosting servers (Gitea) and their
access tokens. Tokens are saved securely and never shown again; to change
one, remove the forge and add it back.</li>
<li><strong>Project directories</strong> — the folders scanned for
repositories. Paths are inside the app's container (under a mounted folder
such as <code>/repos</code>); enable, disable, or remove them.</li>
<li><strong>Git identity</strong> — the name and email used for commits.</li>
</ul>
<h2>Right-click commands</h2>
<p>
Right-click any repository for a menu of plain-language commands — no git
+1 -1
View File
@@ -42,7 +42,7 @@
<header>
<h1>GitManager</h1>
<span style="color: var(--color-fg-muted)">multi-repo dashboard</span>
<nav><a href="/help">Help</a></nav>
<nav><a href="/settings">Settings</a> · <a href="/help">Help</a></nav>
</header>
<main>
<handoff-bar></handoff-bar>
+32
View File
@@ -0,0 +1,32 @@
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>GitManager — Settings</title>
<link rel="stylesheet" href="/static/app.css">
<script type="module" src="/components/settings-panel/settings-panel.js"></script>
<script type="module" src="/components/toast-host/toast-host.js"></script>
<style>
header {
display: flex; align-items: baseline; gap: 16px;
padding: 12px 20px; background: var(--surface-1);
border-bottom: 1px solid var(--border);
}
header h1 { margin: 0; font-size: 16px; }
header nav { margin-left: auto; }
main { max-width: 820px; padding: 20px; }
</style>
</head>
<body>
<header>
<h1>GitManager</h1>
<span style="color: var(--color-fg-muted)">settings</span>
<nav><a href="/">← Dashboard</a></nav>
</header>
<main>
<settings-panel></settings-panel>
</main>
<toast-host></toast-host>
</body>
</html>