Skip to content

pins

lib.pins.refs

The refs pinned in a workflow that never runs, as { "owner/repo" = ref; }: its uses: owner/repo@ref lines, which Dependabot's github-actions ecosystem bumps, whether or not the repository is an action. For sources that are neither images nor flake inputs, such as a release asset.

Arguments

file (Path): the workflow, .github/workflows/pins.yaml

lib.pins.locked

A fixed-output fetch whose hash is in lockFile under name@ref, which lock-images writes. Returns src, the fetch, and for homelab.cluster.sourceLocks, key and unlocked: the fetch with an empty hash, whose mismatch error names the hash.

The ref has to come from the flake that holds lockFile (its pins.yaml, say), never from an input a consumer can override with follows, such as a nixhelm chart's version: a consumer whose input is newer would name a key this lock doesn't have, and its evaluation fails.

Arguments

lockFile (Path): JSON of name@ref to hash

name (String): what is fetched, with anything besides the ref that changes it

ref (String): the pinned ref

fetch (String -> Derivation): the fetch, given its hash