Skip to content

Commit d1dd7ab

Browse files
fricklerhandwerkproofconstructiondjacuroberth
authored
mention the actual meaning of FODs in the glossary (#10888)
* mention the actual meaning of FODs in the glossary Co-authored-by: Alex Groleau <[email protected]> Co-authored-by: Daniel Baker <[email protected]> Co-authored-by: Robert Hensing <[email protected]>
1 parent e943ee3 commit d1dd7ab

File tree

2 files changed

+10
-10
lines changed

2 files changed

+10
-10
lines changed

doc/manual/src/glossary.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -71,10 +71,9 @@
7171
[`__contentAddressed`](./language/advanced-attributes.md#adv-attr-__contentAddressed)
7272
attribute set to `true`.
7373

74-
- [fixed-output derivation]{#gloss-fixed-output-derivation}
74+
- [fixed-output derivation]{#gloss-fixed-output-derivation} (FOD)
7575

76-
A derivation which includes the
77-
[`outputHash`](./language/advanced-attributes.md#adv-attr-outputHash) attribute.
76+
A [derivation] where a cryptographic hash of the [output] is determined in advance using the [`outputHash`](./language/advanced-attributes.md#adv-attr-outputHash) attribute, and where the [`builder`](@docroot@/language/derivations.md#attr-builder) executable has access to the network.
7877

7978
- [store]{#gloss-store}
8079

doc/manual/src/language/advanced-attributes.md

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -120,12 +120,11 @@ Derivations can declare some infrequently used optional attributes.
120120
configuration setting.
121121
122122
- [`outputHash`]{#adv-attr-outputHash}; [`outputHashAlgo`]{#adv-attr-outputHashAlgo}; [`outputHashMode`]{#adv-attr-outputHashMode}\
123-
These attributes declare that the derivation is a so-called
124-
*fixed-output derivation*, which means that a cryptographic hash of
125-
the output is already known in advance. When the build of a
126-
fixed-output derivation finishes, Nix computes the cryptographic
127-
hash of the output and compares it to the hash declared with these
128-
attributes. If there is a mismatch, the build fails.
123+
These attributes declare that the derivation is a so-called *fixed-output derivation* (FOD), which means that a cryptographic hash of the output is already known in advance.
124+
125+
As opposed to regular derivations, the [`builder`] executable of a fixed-output derivation has access to the network.
126+
Nix computes a cryptographic hash of its output and compares that to the hash declared with these attributes.
127+
If there is a mismatch, the derivation fails.
129128
130129
The rationale for fixed-output derivations is derivations such as
131130
those produced by the `fetchurl` function. This function downloads a
@@ -279,7 +278,9 @@ Derivations can declare some infrequently used optional attributes.
279278
280279
> **Note**
281280
>
282-
> If set to `false`, the [`builder`](./derivations.md#attr-builder) should be able to run on the system type specified in the [`system` attribute](./derivations.md#attr-system), since the derivation cannot be substituted.
281+
> If set to `false`, the [`builder`] should be able to run on the system type specified in the [`system` attribute](./derivations.md#attr-system), since the derivation cannot be substituted.
282+
283+
[`builder`]: ./derivations.md#attr-builder
283284
284285
- [`__structuredAttrs`]{#adv-attr-structuredAttrs}\
285286
If the special attribute `__structuredAttrs` is set to `true`, the other derivation

0 commit comments

Comments
 (0)