gunk-dev/the-valley

host.cue

sourcec7b2912a5496main's published tip history
1.2 KiB
1// A worked valley host declaration: one project with a publication mirror,
2// and a backup. This file is the single domain input: the NixOS
3// module validates it against schema/valley.cue and provisions the host
4// from it. Machines never redefine what is declared here.
5//
6// Validate: cue vet -c schema/valley.cue examples/host.cue
7// Export: cue export schema/valley.cue examples/host.cue
8package valley
9
10projects: {
11 // The project (archive/design/user-scenarios.md § S1), with a
12 // publication mirror: every push to the primary replicates main and
13 // the tags there, best-effort.
14 // Topic branches awaiting review stay on the primary (dcr-24d62f7).
15 //
16 // git.enable defaults to true — git is the only store type today.
17 "the-valley": {
18 mirrors: ["git@mirror.example.org:the-valley.git"]
19 }
20}
21
22// The durability policy (dcr-d7952bc): nightly encrypted restic
23// snapshots of the host's data to an sftp server.
24// cadence and retention take the defaults — nightly, 7 daily / 4 weekly /
25// 6 monthly. The repository URL, credentials, and pinned host key are
26// machine integration, supplied by the consumer to the installer
27// (services.valley.backup.*), never declared here.
28backup: {
29 target: "restic-sftp"
30}