diff options
author | pennae <github@quasiparticle.net> | 2021-12-05 21:28:49 +0100 |
---|---|---|
committer | pennae <github@quasiparticle.net> | 2021-12-09 01:13:48 +0100 |
commit | fb0e5be84331188a69b3edd31679ca6576edb75a (patch) | |
tree | 80d713f568ae02e4a3aed70114bafe46e9fe753f /nixos/modules/services/misc/exhibitor.nix | |
parent | f6d0b014fe1db9e6edec5485f41a1162136c8a70 (diff) | |
download | nixpkgs-fb0e5be84331188a69b3edd31679ca6576edb75a.tar nixpkgs-fb0e5be84331188a69b3edd31679ca6576edb75a.tar.gz nixpkgs-fb0e5be84331188a69b3edd31679ca6576edb75a.tar.bz2 nixpkgs-fb0e5be84331188a69b3edd31679ca6576edb75a.tar.lz nixpkgs-fb0e5be84331188a69b3edd31679ca6576edb75a.tar.xz nixpkgs-fb0e5be84331188a69b3edd31679ca6576edb75a.tar.zst nixpkgs-fb0e5be84331188a69b3edd31679ca6576edb75a.zip |
treewide: add defaultText for options with simple interpolation defaults
adds defaultText for all options that use `cfg.*` values in their defaults, but only for interpolations with no extra processing (other than toString where necessary)
Diffstat (limited to 'nixos/modules/services/misc/exhibitor.nix')
-rw-r--r-- | nixos/modules/services/misc/exhibitor.nix | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/nixos/modules/services/misc/exhibitor.nix b/nixos/modules/services/misc/exhibitor.nix index 28c98edf47a..4c935efbd84 100644 --- a/nixos/modules/services/misc/exhibitor.nix +++ b/nixos/modules/services/misc/exhibitor.nix @@ -1,9 +1,10 @@ -{ config, lib, pkgs, ... }: +{ config, lib, options, pkgs, ... }: with lib; let cfg = config.services.exhibitor; + opt = options.services.exhibitor; exhibitorConfig = '' zookeeper-install-directory=${cfg.baseDir}/zookeeper zookeeper-data-directory=${cfg.zkDataDir} @@ -165,6 +166,7 @@ in zkDataDir = mkOption { type = types.str; default = "${cfg.baseDir}/zkData"; + defaultText = literalExpression ''"''${config.${opt.baseDir}}/zkData"''; description = '' The Zookeeper data directory ''; @@ -172,6 +174,7 @@ in zkLogDir = mkOption { type = types.path; default = "${cfg.baseDir}/zkLogs"; + defaultText = literalExpression ''"''${config.${opt.baseDir}}/zkLogs"''; description = '' The Zookeeper logs directory ''; |