quagga module: Use a deep merge via imports instead of the shallow merge

The deep merge caused all the options to be unset when generating docs, unless quagga was enabled.

Using imports, instead, properly allows the documentation to be generated.
This commit is contained in:
Graham Christensen 2018-07-05 22:10:44 -04:00
parent 62f47c56b7
commit 078925c954
No known key found for this signature in database
GPG Key ID: ACA1C1D120C83D5C
1 changed files with 15 additions and 16 deletions

View File

@ -95,12 +95,10 @@ in
{ {
###### interface ###### interface
imports = [
options.services.quagga =
{ {
options.services.quagga = {
zebra = (serviceOptions "zebra") // { zebra = (serviceOptions "zebra") // {
enable = mkOption { enable = mkOption {
type = types.bool; type = types.bool;
default = any isEnabled services; default = any isEnabled services;
@ -111,10 +109,11 @@ in
if any routing protocols are configured. if any routing protocols are configured.
''; '';
}; };
}; };
};
} // (genAttrs services serviceOptions); }
{ options.services.quagga = (genAttrs services serviceOptions); }
];
###### implementation ###### implementation