crosscode: --json reports, --config, env templates, frpc tunnels, restart/export/uninstall/purge

- Every command takes --json (crosscode.script-report/1 on stdout, the
  log on stderr) and --config (the .env values by layer, from the agent).
- .env files come from the release's env.template.json (lib/envtpl.js):
  written whole on install; on deploy only new variables are appended,
  and a new required one with no value stops the deploy at the checks.
- install --frp: Hub-given ports, a marked frpc.ini block (backup,
  frpc verify, reload; [common] admin lines added once), no nginx.
  A database on another server via DB_ADMIN_URL. Refuses an existing
  database or role. Everything the run made is removed if it fails.
- restart, export (crosscode.church-export/1 ZIP), uninstall (final
  backup, uploads and .env kept 30 days) and purge.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-17 12:50:19 +02:00
co-authored by Claude Opus 5.5
parent 350ab9f4e8
commit e9e9b5a97f
17 changed files with 1308 additions and 88 deletions
+1 -1
View File
@@ -16,7 +16,7 @@
"test:scripts": "bats scripts/tests",
"typecheck": "npm run typecheck --workspaces --if-present",
"lint": "eslint .",
"lint:scripts": "shellcheck -x scripts/crosscode scripts/products/events.sh",
"lint:scripts": "shellcheck -x scripts/crosscode scripts/products/events.sh scripts/lib/report.sh scripts/lib/env.sh scripts/lib/frpc.sh scripts/lib/manage.sh",
"check": "npm run lint && npm run lint:scripts && npm run typecheck && npm test && npm run test:scripts && npm run build"
},
"engines": {