From 5ec7ee21e036f7bc1cbdec714271c619cb3fdb3d Mon Sep 17 00:00:00 2001 From: seth Date: Sun, 27 Oct 2024 20:12:19 -0400 Subject: modules: restructure (#487) * seth: remove unused pkgs * modules: restructure from archetypes back to profiles make less actual modules for everything use lib.mkDefault like it's supposed to move mixins out of server * nixos/resolved: use modern options --- modules/nixos/server/mixins/promtail.nix | 48 -------------------------------- 1 file changed, 48 deletions(-) delete mode 100644 modules/nixos/server/mixins/promtail.nix (limited to 'modules/nixos/server/mixins/promtail.nix') diff --git a/modules/nixos/server/mixins/promtail.nix b/modules/nixos/server/mixins/promtail.nix deleted file mode 100644 index 173a85b..0000000 --- a/modules/nixos/server/mixins/promtail.nix +++ /dev/null @@ -1,48 +0,0 @@ -{ config, lib, ... }: -let - cfg = config.server.mixins.promtail; - inherit (lib) types; -in -{ - options.server.mixins.promtail = { - enable = lib.mkEnableOption "Promtail mixin"; - - clients = lib.mkOption { - type = types.listOf types.attrs; - default = [ { } ]; - defaultText = lib.literalExpression "[ { } ]"; - description = "Clients for promtail"; - }; - }; - - config = lib.mkIf cfg.enable { - services.promtail = { - enable = true; - configuration = { - inherit (cfg) clients; - server.disable = true; - - scrape_configs = [ - { - job_name = "journal"; - - journal = { - max_age = "12h"; - labels = { - job = "systemd-journal"; - host = "${config.networking.hostName}"; - }; - }; - - relabel_configs = [ - { - source_labels = [ "__journal__systemd_unit" ]; - target_label = "unit"; - } - ]; - } - ]; - }; - }; - }; -} -- cgit v1.2.3