feat(executor): execution spine — place → grant → verify → dispatch → receipt + sourceosctl CLI - #19
Merged
Merged
Conversation
…PATCH -> receipt
Closes the loop from governed decision plane to a platform that actually runs work.
tools/executor.py — turns a placement decision + a verified Grant into a real dispatch:
- LocalAdapter: real subprocess (--apply).
- K8sAdapter: real batch/v1 Job manifest, Grant-labelled; kubectl apply when a cluster
is reachable, else emitted.
- DescriptorAdapter: substrate-specific descriptor for hpc-slurm / wasm-edge / p2p-mesh /
volunteer-boinc / blockchain-rlc, to hand that scheduler over a Grant-bound channel.
- execute(): re-verifies the Grant at the node (fail-closed DispatchRefused on bad sig /
wrong session / expired / effect-not-granted / unknown backend), then dispatches, then
seals a receipt.
- run_spine(): the one call — place -> issue_grant -> verify_grant -> execute.
tools/sourceosctl.py — the developer front door, one command from a low-mem box:
`sourceosctl run --gpu --sensitivity sensitive --command "python train.py"` reads the live
mesh, places under policy, mints+verifies a Grant, dispatches, prints where it ran + the
sealed receipt. Also `mesh`, `place` (dry), `commons`. DEV MODE (synthesized attestation +
HMAC key) when SOURCEOS_SIGNING_KEY is unset — says so loudly.
Governance holds end to end: a sensitive GPU workload lands on trusted HPC, never the bigger
volunteer grid; only-untrusted-live -> blocked, dispatched nowhere.
Tests: +10 executor (adapters, fail-closed, full spine) +5 CLI = 81 tools tests green.
Wired: validate REQUIRED, Makefile spine/run targets, compute-plane CapD links,
docs/EXECUTION_SPINE.md.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Closes the loop from a governed decision plane to a platform that actually runs work. A workload dispatched from a low-mem box places under policy, mints + verifies a zero-trust Grant, and dispatches to whatever substrate the mesh offers — fail-closed, sealed.
tools/executor.py--apply).batch/v1Job manifest;kubectl applywhen a cluster is reachable, else emitted.hpc-slurm/wasm-edge/p2p-mesh/volunteer-boinc/blockchain-rlc.execute()re-verifies the Grant at the node (fail-closedDispatchRefusedon bad sig / wrong session / expired / effect-not-granted / unknown backend), dispatches, seals a receipt.run_spine()— the one call: place → issue_grant → verify_grant → execute.tools/sourceosctl.py— the developer front doorrun(+--apply),mesh,place(dry),commons. DEV MODE (synthesized attestation + HMAC key) whenSOURCEOS_SIGNING_KEYis unset — printed loudly; in production the Grant is signed by the Key Authority and attestation comes from the node TPM/TEE + cosign.Governance holds end to end
Sensitive GPU workload → trusted HPC, never the bigger volunteer grid; only-untrusted-live → blocked, dispatched nowhere.
Tests
+10 executor (adapters, fail-closed edges, full spine) +5 CLI = 81 tools tests green;
validatepasses; live CLI smoke verified. Wired: validate REQUIRED, Makefilespine/run, compute-plane CapD links,docs/EXECUTION_SPINE.md.