mesh/delivery-group group feat/sdk1 rejected: composed together: the checker's verdict at the members' heads (428d048dd50a): unit: git.novox.be/novox/mesh-sdk/…
mesh/delivery closed: a newer head of the same pull request
mesh/check failed: unit: git.novox.be/novox/mesh-sdk/go/process.TestStatePutWritesAKeyWhole: a Put through a short blackout: 0, mesh-mail's state send…
Claude-Session: https://claude.ai/code/session_01NcbgfJ9Gum47zkFKWRaovL
38 lines
2.2 KiB
Go
38 lines
2.2 KiB
Go
package catalogue
|
|
|
|
// RuntimeModule is the module that is the node's tool runtime. Mirrored in the broker package,
|
|
// which composes a principal of its own for it; the agreement test there holds the two to one string.
|
|
const RuntimeModule = "node-tools"
|
|
|
|
// BundleRoot is where a machine keeps the tools bundles the mesh delivers to it: under the mesh's
|
|
// own directory, beside the daemons the host unpacks there, and never where a package manager also
|
|
// writes. One directory per module, one per bundle beneath it, at a path that does not move with
|
|
// the version — so the runtime's process names each entrypoint once and is restarted, not
|
|
// recomposed, when a bundle changes.
|
|
const BundleRoot = "/var/lib/mesh/bundles"
|
|
|
|
// RuntimeToolModules is the variable the runtime reads the modules it serves from: one
|
|
// `<module>=<entrypoint>` per file it loads, comma-separated — several entries may name one module.
|
|
// RuntimeBrokerFile is where it reads the node's credential; RuntimeOperatorAccount and
|
|
// RuntimeOperatorHome are the machine's operator account and home, handed to every tool's
|
|
// environment (to-be 38 WP1), and absent on a machine with no account.
|
|
const (
|
|
RuntimeToolModules = "MESH_TOOL_MODULES"
|
|
RuntimeBrokerFile = "MESH_BROKER_FILE"
|
|
RuntimeOperatorAccount = "MESH_OPERATOR_ACCOUNT"
|
|
RuntimeOperatorHome = "MESH_OPERATOR_HOME"
|
|
// RuntimeAgentAccount and RuntimeAgentHome are the account agents run as on the machine and its home
|
|
// (novox/hq ADR 0266): the agent account where the node names one, the operator account otherwise.
|
|
// The agent's module writes the agent's home from them; absent where neither account is known.
|
|
RuntimeAgentAccount = "MESH_AGENT_ACCOUNT"
|
|
RuntimeAgentHome = "MESH_AGENT_HOME"
|
|
// RuntimeToolEnv is every served module's composed environment, as JSON (novox/hq ADR 0192):
|
|
// {"<module>": {"<word>": "<value>"}}. The runtime takes it at start, removes it from its own
|
|
// environment and hands each module's words to that module's bundles alone. In the unit, so a
|
|
// change to any module's words changes the process and restarts it.
|
|
RuntimeToolEnv = "MESH_TOOL_ENV"
|
|
)
|
|
|
|
// OwnRuntimeID names the process a module of its own account is served by (novox/hq ADR 0259 §8).
|
|
func OwnRuntimeID() string { return "own-runtime" }
|