nixos/grafana: Don't print password warning if no password has been set
This commit is contained in:
parent
46904e9c3a
commit
cda4a4dcfc
@ -1,4 +1,4 @@
|
|||||||
{ config, lib, pkgs, ... }:
|
{ options, config, lib, pkgs, ... }:
|
||||||
|
|
||||||
with lib;
|
with lib;
|
||||||
|
|
||||||
@ -232,9 +232,10 @@ in {
|
|||||||
};
|
};
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
warnings = [
|
warnings = optional (
|
||||||
"Grafana passwords will be stored as plaintext in the Nix store!"
|
cfg.database.password != options.services.grafana.database.password.default ||
|
||||||
];
|
cfg.security.adminPassword != options.services.grafana.security.adminPassword.default
|
||||||
|
) "Grafana passwords will be stored as plaintext in the Nix store!";
|
||||||
|
|
||||||
environment.systemPackages = [ cfg.package ];
|
environment.systemPackages = [ cfg.package ];
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user