Docs: explain inventory imports
This commit is contained in:
@@ -20,6 +20,32 @@ let
|
|||||||
};
|
};
|
||||||
|
|
||||||
importsOption = lib.mkOption {
|
importsOption = lib.mkOption {
|
||||||
|
description = ''
|
||||||
|
List of imported '.nix' files.
|
||||||
|
|
||||||
|
Each filename must be a string and is interpreted relative to the 'directory' passed to buildClan.
|
||||||
|
The import only happens if the machine is part of the service or role.
|
||||||
|
|
||||||
|
## Example
|
||||||
|
|
||||||
|
To import the `special.nix` file
|
||||||
|
|
||||||
|
```
|
||||||
|
. Clan Directory
|
||||||
|
├── flake.nix
|
||||||
|
...
|
||||||
|
└── modules
|
||||||
|
├── special.nix
|
||||||
|
└── ...
|
||||||
|
```
|
||||||
|
|
||||||
|
```nix
|
||||||
|
{
|
||||||
|
imports = [ "modules/special.nix" ];
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
'';
|
||||||
default = [ ];
|
default = [ ];
|
||||||
type = types.listOf types.str;
|
type = types.listOf types.str;
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user