diff options
author | zimbatm <zimbatm@zimbatm.com> | 2019-12-28 20:36:42 +0000 |
---|---|---|
committer | Wael Nasreddine <wael.nasreddine@gmail.com> | 2019-12-28 12:36:42 -0800 |
commit | f373ecec8f49b24c3070ab4f66a680bee06980a5 (patch) | |
tree | 0d892fc2a010529511abd8b39cb666474a089f21 /doc/languages-frameworks | |
parent | 596fa2844824bd51653b0ca7ccd4d92dcefdfd0d (diff) |
buildGoModule: support impure modules (#76532)
When modSha256 is null, disable the nix sandbox instead of using a
fixed-output derivation. This requires the nix-daemon to have
`sandbox = relaxed` set in their config to work properly.
Because the output is (hopefully) deterministic based on the inputs,
this should give a reproducible output. This is useful for development
outside of nixpkgs where re-generating the modSha256 on each mod.sum
changes is cumbersome.
Don't use this in nixpkgs! This is why null is not the default value.
Diffstat (limited to 'doc/languages-frameworks')
-rw-r--r-- | doc/languages-frameworks/go.xml | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/doc/languages-frameworks/go.xml b/doc/languages-frameworks/go.xml index bd1ee8eba275..53c891e66f87 100644 --- a/doc/languages-frameworks/go.xml +++ b/doc/languages-frameworks/go.xml @@ -66,6 +66,15 @@ pet = buildGoModule rec { </callout> </calloutlist> </para> + + <para> + <varname>modSha256</varname> can also take <varname>null</varname> as an input. + + When `null` is used as a value, the derivation won't be a + fixed-output derivation but disable the build sandbox instead. This can be useful outside + of nixpkgs where re-generating the modSha256 on each mod.sum changes is cumbersome, + but will fail to build by Hydra, as builds with a disabled sandbox are discouraged. + </para> </section> <section xml:id="ssec-go-legacy"> |