diff --git a/doc/functions.xml b/doc/functions.xml index 5378b59abcb2..39010f8ab145 100644 --- a/doc/functions.xml +++ b/doc/functions.xml @@ -236,6 +236,20 @@ c = lib.makeOverridable f { a = 1; b = 2; } runScript parameter, which is a command that would be executed inside the sandbox and passed all the command line arguments. It default to bash. + + + It also uses CHROOTENV_EXTRA_BINDS environment variable + for binding extra directories in the sandbox to outside places. The format of + the variable is /mnt=test-mnt:/data, where + /mnt would be mounted as /test-mnt + and /data would be mounted as /data. + extraBindMounts array argument to + buildFHSUserEnv function is prepended to this variable. + Latter entries take priority if defined several times -- i.e. in case of + /data=data1:/data=data2 the actual bind path would be + /data2. + + One can create a simple environment using a shell.nix like that: