mesh/merge-gate checking again: the gate refused `unknown` because the controller judged with a node-engine validator pinned before mesh-host #117; mesh-co…
mesh/repo-check checking again: the gate refused `unknown` because the controller judged with a node-engine validator pinned before mesh-host #117; mesh-co…
mesh/delivery-group group feat/owned-paths checking: 0 of 2 member(s) ready
mesh/delivery superseded: a newer head of the same pull request
Every directory and archive resource carries `unknown`: move-out for a home folder whose program writes nothing there (the node-engine, delivered in mesh-host #117, moves the rest to ~/.local/state/mesh-moved/<module>/ with a list), module for ~/.ssh and ~/.claude, program elsewhere; `knows` keeps what a program or the operator relies on (powerlevel10k's compiled files, i3's scripts and the asus/g14 drop-ins, dunst's slack rule, betterbird's records, node-env's forge credential, issue 1033). Two shared folders are no longer declared. Each module's README says it. checks/owned holds every manifest to it; checks/sshdir stays while main's merge check runs it (issue 1035). Tests that pin a manifest follow the new key only. Reviewed in three rounds.
185 lines
4.2 KiB
JSON
185 lines
4.2 KiB
JSON
{
|
|
"module": "claude-licence-manager",
|
|
"version": "1",
|
|
"slug": "licmgr",
|
|
"requires": [
|
|
"postgres-database",
|
|
"secret"
|
|
],
|
|
"contributes": {
|
|
"postgres-database": {
|
|
"name": "claude_licences",
|
|
"readable": [
|
|
"audit",
|
|
"binding"
|
|
]
|
|
}
|
|
},
|
|
"binds": {
|
|
"postgres-database": "${dir:state}/database.json"
|
|
},
|
|
"secrets": {
|
|
"postgres-database": "${dir:state}/database.secret",
|
|
"secret": {
|
|
"grant-key": "${dir:state}/grant.key"
|
|
}
|
|
},
|
|
"seats": [
|
|
{
|
|
"name": "anthropic-licence-manager",
|
|
"scope": "mesh",
|
|
"serves": [
|
|
"licences",
|
|
"bindings",
|
|
"bind",
|
|
"switch",
|
|
"release",
|
|
"refresh",
|
|
"usage",
|
|
"adopt",
|
|
"current",
|
|
"public-key"
|
|
]
|
|
}
|
|
],
|
|
"claims": [
|
|
{
|
|
"name": "anthropic-licence-manager",
|
|
"scope": "mesh",
|
|
"serves": [
|
|
"licences",
|
|
"bindings",
|
|
"bind",
|
|
"switch",
|
|
"release",
|
|
"refresh",
|
|
"usage",
|
|
"adopt",
|
|
"current",
|
|
"public-key"
|
|
]
|
|
}
|
|
],
|
|
"emits": [
|
|
"licence.adopted",
|
|
"licence.refused",
|
|
"licence.bound",
|
|
"licence.switched",
|
|
"licence.released",
|
|
"licence.rotated",
|
|
"licence.failing",
|
|
"usage.read"
|
|
],
|
|
"state": [
|
|
"bindings"
|
|
],
|
|
"reads": [
|
|
"claude-code.holdings"
|
|
],
|
|
"config": {
|
|
"cadence_minutes": {
|
|
"type": "number",
|
|
"description": "How old a licence's grant may grow before it is rotated, in minutes; 0 keeps 240.",
|
|
"minimum": 0,
|
|
"trusted": true,
|
|
"default": 240
|
|
},
|
|
"floor_minutes": {
|
|
"type": "number",
|
|
"description": "How little time a grant may have left before it is refreshed in any case, in minutes; 0 keeps 60.",
|
|
"minimum": 0,
|
|
"trusted": true,
|
|
"default": 60
|
|
},
|
|
"failures_to_notify": {
|
|
"type": "number",
|
|
"description": "How many refreshes of a licence fail in a row before the operator is told, a count; 0 keeps 3.",
|
|
"minimum": 0,
|
|
"trusted": true,
|
|
"default": 3
|
|
},
|
|
"cooldown_hours": {
|
|
"type": "number",
|
|
"description": "How long after telling the operator about a licence nothing more is said about it, in hours; 0 keeps 24.",
|
|
"minimum": 0,
|
|
"trusted": true,
|
|
"default": 24
|
|
},
|
|
"refresh_warn_days": {
|
|
"type": "number",
|
|
"description": "How long before a licence's refresh token itself expires the operator is warned, in days; 0 keeps 3.",
|
|
"minimum": 0,
|
|
"trusted": true,
|
|
"default": 3
|
|
}
|
|
},
|
|
"resources": [
|
|
{
|
|
"id": "state",
|
|
"type": "directory",
|
|
"mode": "0700",
|
|
"place": ".",
|
|
"unknown": "program"
|
|
},
|
|
{
|
|
"id": "database-url",
|
|
"type": "file",
|
|
"path": "${dir:state}/database.url",
|
|
"mode": "0600",
|
|
"template": "files/database.url"
|
|
},
|
|
{
|
|
"id": "settings",
|
|
"type": "file",
|
|
"path": "${dir:state}/settings.json",
|
|
"mode": "0600",
|
|
"takes-config": ["cadence_minutes", "floor_minutes", "failures_to_notify", "cooldown_hours", "refresh_warn_days"],
|
|
"merge": "json",
|
|
"template": "files/settings.json"
|
|
},
|
|
{
|
|
"id": "prepare",
|
|
"type": "process",
|
|
"name": "claude-licence-manager-prepare",
|
|
"artifact": "code",
|
|
"run": [
|
|
"./claude-licence-manager",
|
|
"prepare"
|
|
],
|
|
"run-once": true,
|
|
"env": {
|
|
"DATABASE_URL_FILE": "${dir:state}/database.url"
|
|
},
|
|
"restart-on": [
|
|
"database-url"
|
|
]
|
|
}
|
|
],
|
|
"build": {
|
|
"artifacts": [
|
|
{
|
|
"name": "code",
|
|
"kind": "bundle",
|
|
"language": "go",
|
|
"system": "arch",
|
|
"from": "cmd/claude-licence-manager",
|
|
"binary": "claude-licence-manager",
|
|
"loads": [
|
|
"claude-licence-manager"
|
|
],
|
|
"env": {
|
|
"DATABASE_URL_FILE": "${dir:state}/database.url",
|
|
"MESH_LICENCE_STATE": "${dir:state}",
|
|
"MESH_LICENCE_KEY_FILE": "${dir:state}/grant.key",
|
|
"MESH_LICENCE_SETTINGS": "${dir:state}/settings.json"
|
|
}
|
|
},
|
|
{
|
|
"name": "files",
|
|
"kind": "archive",
|
|
"from": "files"
|
|
}
|
|
]
|
|
}
|
|
}
|