Components
Pipelines use published components (uses: hod/setup-go@v1) pinned in
hod.lock (hod.lock reference). Before a run
compiles, the server fetches each locked digest with its own registry
credentials, caches the files, and checks the org's policy: the source is
allowed, the version isn't blocked, and the signature is the source's.
Runners get the files from the server, never from the registry. hod component update on a machine logged in to the server resolves through
it, under the same policy.
Policy
- Globs are anchored:
*stays within a/-separated segment,**crosses segments. Identities are matched the same way, never as regexes. hod/components are signed with the Hod project key, built into Hod. Pulling one reachesregistry.hod.shandpkg-containers.githubusercontent.com(GHCR's blobs), so egress allow lists need both.hod_prefixandhod_key_filepointhod/at a mirror signed with a key of your own.- The cooldown counts from the signature's proved time, or from when the server first saw the version; never from a date the publisher wrote.
- The policy is stored per org in Postgres and replaced from this file on every start. Blocking a version stops the next run that uses it, even if it is already locked.
Secrets sealed to components
-
A secret sealed to components (
hod secret set DEPLOY_KEY --component hod/deploy) is released only to steps running one of them withruns: container, in a container of its own. Those steps can't setenv:ordir:, and they get none of the job'senv:or what earlier components exported, only Hod's own variables, their inputs and their grants, with their image's ownPATH. Pass what the component needs aswith:inputs. Aruns: jobcomponent runs among the job's processes, which could read its secret, so the seal refuses it. -
The seal also pins where the secret goes. A component marks the inputs that say where it sends things (
destination: true, such as a registry). A sealed step must leave each at its default, or set it to a value the secret pins:Repeat
--withfor more inputs, or for more values of one. Values are compared exactly, and must be known when the job starts, not read from earlier steps. A destination with no default needs a pin.--componentwithout--withkeeps the pins if it names the same components, and clears them if it names others, so pins never carry over to other components;--no-withremoves the pins;--no-componentsremoves the seal and its pins. -
A component's
network:may name an input (inputs.registry): the egress guard allows that input's host, so a pinned internal registry is the host it opens, not the public one.