Accounts: deploy hooks, env template, export, docs

scripts/products/accounts.sh (backup with pg_dump, build with the shared
packages, PM2, export, keep, failed-migration recovery); accounts in
SUPPORTED_PRODUCTS so deploy updates it where a church has it. Env
template in both places, PM2 example, export script, /api/health
version from package.json. README, CHANGELOG, WHATS-NEW; the plan's
changes while building and what's still to do.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-18 14:18:40 +02:00
co-authored by Claude Opus 5.5
parent a3e3921b4f
commit 7f34e184e1
17 changed files with 374 additions and 12 deletions
+2 -3
View File
@@ -9,6 +9,7 @@ import { hub } from '@crosscode/contracts';
import type { Ctx } from '../context.js';
import { hubPublicKey, verifyToken } from './licence.js';
import { keyPair, saveLinkedProducts } from '../links/store.js';
import { appVersion } from '../lib/version.js';
export const PROTOCOL_VERSION = 2;
const TIMEOUT_MS = 15000;
@@ -41,9 +42,7 @@ async function post(ctx: Ctx, path: string, body: unknown, sign?: { installId: s
return data;
}
function version(): string {
return process.env.npm_package_version || '1.0.0';
}
const version = appVersion;
export async function health(ctx: Ctx) {
let db = true;