treewide: fix statix errors

This commit is contained in:
Felix Buehler 2023-11-07 23:13:51 +01:00
parent a4b8c2b8da
commit 743d7eead9
48 changed files with 72 additions and 82 deletions

View file

@ -83,22 +83,21 @@ in
type = "local";
local = {
# having the "fake" directory is important, because loki is running in single-tenant mode
directory = (pkgs.writeTextDir "fake/loki-rules.yml" (builtins.toJSON {
directory = pkgs.writeTextDir "fake/loki-rules.yml" (builtins.toJSON {
groups = [
{
name = "alerting-rules";
rules = lib.mapAttrsToList
(name: opts: {
alert = name;
expr = opts.condition;
inherit (opts) condition labels;
for = opts.time;
labels = opts.labels;
annotations.description = opts.description;
})
(cfg.rules);
cfg.rules;
}
];
}));
});
};
};