Skip to content

Nix required mounts

programs.nix-required-mounts.allowedPatterns

The hook config, describing which paths to mount for which system features Type: attribute set of (submodule)

Default

{opengl.paths = config.hardware.opengl.extraPackages ++ [config.hardware.opengl.packagepkgs.addOpenGLRunpath.driverLink"/dev/dri"];}

Example

{require-ipfs = {onFeatures = ["ifps"];paths = ["/ipfs"];};}

Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/programs/nix-required-mounts.nix

programs.nix-required-mounts.allowedPatterns.<name>.onFeatures

Which requiredSystemFeatures should trigger relaxation of the sandbox Type: list of string

Default

["‹name›"]

Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/programs/nix-required-mounts.nix

programs.nix-required-mounts.allowedPatterns.<name>.paths

A list of glob patterns, indicating which paths to expose to the sandbox Type: list of (path or (submodule))

Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/programs/nix-required-mounts.nix

Whether to enable Instructs the hook to mount the symlink targets as well, when any of the paths contain symlinks. This may not work correctly with glob patterns. . Type: boolean

Default

false

Example

true

Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/programs/nix-required-mounts.nix

programs.nix-required-mounts.enable

Whether to enable Expose extra paths to the sandbox depending on derivations' requiredSystemFeatures. Type: boolean

Default

false

Example

true

Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/programs/nix-required-mounts.nix

programs.nix-required-mounts.extraWrapperArgs

List of extra arguments (such as --add-flags -v) to pass to the hook's wrapper Type: list of string

Default

[ ]

Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/programs/nix-required-mounts.nix

programs.nix-required-mounts.presets.nvidia-gpu.enable

Whether to enable Declare the support for derivations that require an Nvidia GPU to be available, e.g. derivations with requiredSystemFeatures = [ "cuda" ]. This mounts the corresponding userspace drivers and device nodes in the sandbox, but only for derivations that request these special features.

You may extend or override the exposed paths via the programs.nix-required-mounts.allowedPatterns.nvidia-gpu.paths option. . Type: boolean

Default

false

Example

true

Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/programs/nix-required-mounts.nix