From 025d62478a50f99ba266c362bc729d4e6987b108 Mon Sep 17 00:00:00 2001 From: mesh-tools Date: Wed, 21 Oct 2026 09:21:19 +0000 Subject: [PATCH] Add the go and nodejs modules, which own the toolchain packages and provide go-toolchain and node-toolchain (issue 1573) --- modules/go/README.md | 11 +++++++++++ modules/go/module.json | 20 ++++++++++++++++++++ modules/nodejs/README.md | 12 ++++++++++++ modules/nodejs/module.json | 25 +++++++++++++++++++++++++ 4 files changed, 68 insertions(+) create mode 100644 modules/go/README.md create mode 100644 modules/go/module.json create mode 100644 modules/nodejs/README.md create mode 100644 modules/nodejs/module.json diff --git a/modules/go/README.md b/modules/go/README.md new file mode 100644 index 00000000..25e8210b --- /dev/null +++ b/modules/go/README.md @@ -0,0 +1,11 @@ +# go + +The Go toolchain as a module (novox/hq ADR 0477 §4, issue 1573). + +- **Owns the package `go`.** No other module declares it (`checks/toolchains` refuses one that does). +- **Provides `go-toolchain` with the machine's reach**: dev-tools, lab and mesh-build-go require it, and the + requirement is met only by this module on the same machine. It is never pulled in for whatever asked, so + `go` is assigned to a node on purpose, and a node without it refuses a module that needs it at resolution. +- Holds no long-running resource, so it adds nothing to `health-undeclared`. + +The node-engine never uninstalls a package, so moving the declaration here removes nothing from a node. diff --git a/modules/go/module.json b/modules/go/module.json new file mode 100644 index 00000000..48a6bf57 --- /dev/null +++ b/modules/go/module.json @@ -0,0 +1,20 @@ +{ + "module": "go", + "version": "1", + "capabilities": [ + "package-manager" + ], + "provides": [ + { + "name": "go-toolchain", + "reach": "machine" + } + ], + "resources": [ + { + "id": "go", + "type": "package", + "package": "go" + } + ] +} diff --git a/modules/nodejs/README.md b/modules/nodejs/README.md new file mode 100644 index 00000000..375b0900 --- /dev/null +++ b/modules/nodejs/README.md @@ -0,0 +1,12 @@ +# nodejs + +Node.js and npm as a module (novox/hq ADR 0477 §4, issue 1573). + +- **Owns the packages `nodejs` and `npm`.** No other module declares them (`checks/toolchains` refuses one that + does). +- **Provides `node-toolchain` with the machine's reach**: dev-tools, lab and mesh-build-node require it, and the + requirement is met only by this module on the same machine. It is never pulled in for whatever asked, so + `nodejs` is assigned to a node on purpose, and a node without it refuses a module that needs it at resolution. +- Holds no long-running resource, so it adds nothing to `health-undeclared`. + +The node-engine never uninstalls a package, so moving the declaration here removes nothing from a node. diff --git a/modules/nodejs/module.json b/modules/nodejs/module.json new file mode 100644 index 00000000..c3573444 --- /dev/null +++ b/modules/nodejs/module.json @@ -0,0 +1,25 @@ +{ + "module": "nodejs", + "version": "1", + "capabilities": [ + "package-manager" + ], + "provides": [ + { + "name": "node-toolchain", + "reach": "machine" + } + ], + "resources": [ + { + "id": "nodejs", + "type": "package", + "package": "nodejs" + }, + { + "id": "npm", + "type": "package", + "package": "npm" + } + ] +}