@cryptotaxi247 / infra-1 / commits / 33a4bf96

Reformat with nixfmt 1.0.0

Martin Weinelt committed Jul 30, 2025 at 09:03 UTC 33a4bf960dee5fb2307fbc3767bf35a532b34e9b
3 files changed +37 -39
build/colmena.nix
+14 -15
@@ -54,19 +54,18 @@
54 };
55 };
56 config.flake.colmenaHive = inputs.colmena.lib.makeHive self.outputs.colmena;
57 - config.flake.colmena =
58 - {
59 - meta = {
60 - nixpkgs = inputs.nixpkgs.legacyPackages.${config.colmena.system};
61 - # https://github.com/zhaofengli/colmena/issues/60#issuecomment-1510496861
62 - nodeSpecialArgs = builtins.mapAttrs (_: value: value._module.specialArgs) self.nixosConfigurations;
63 - };
64 - }
65 - // builtins.mapAttrs (name: _: {
66 - imports = (self.nixosConfigurations.${name})._module.args.modules ++ [
67 - {
68 - deployment = config.colmena.hosts.${name};
69 - }
70 - ];
71 - }) config.colmena.hosts;
57 + config.flake.colmena = {
58 + meta = {
59 + nixpkgs = inputs.nixpkgs.legacyPackages.${config.colmena.system};
60 + # https://github.com/zhaofengli/colmena/issues/60#issuecomment-1510496861
61 + nodeSpecialArgs = builtins.mapAttrs (_: value: value._module.specialArgs) self.nixosConfigurations;
62 + };
63 + }
64 + // builtins.mapAttrs (name: _: {
65 + imports = (self.nixosConfigurations.${name})._module.args.modules ++ [
66 + {
67 + deployment = config.colmena.hosts.${name};
68 + }
69 + ];
70 + }) config.colmena.hosts;
71 }
build/pluto/prometheus/exporters/channel.nix
+20 -21
@@ -24,27 +24,26 @@ in
24 };
25 };
26
27 - services.prometheus.scrapeConfigs =
28 - [
27 + services.prometheus.scrapeConfigs = [
28 + {
29 + job_name = "channel-updates";
30 + metrics_path = "/";
31 + static_configs = [ { targets = [ "127.0.0.1:9402" ]; } ];
32 + }
33 + ]
34 + ++ lib.mapAttrsToList (name: value: {
35 + job_name = "channel-job-${name}";
36 + scheme = "https";
37 + scrape_interval = "5m";
38 + metrics_path = "/job/${value.job}/prometheus";
39 + static_configs = [
40 {
30 - job_name = "channel-updates";
31 - metrics_path = "/";
32 - static_configs = [ { targets = [ "127.0.0.1:9402" ]; } ];
41 + labels = {
42 + current = if value.status != "unmaintained" then "1" else "0";
43 + channel = name;
44 + };
45 + targets = [ "hydra.nixos.org:443" ];
46 }
34 - ]
35 - ++ lib.mapAttrsToList (name: value: {
36 - job_name = "channel-job-${name}";
37 - scheme = "https";
38 - scrape_interval = "5m";
39 - metrics_path = "/job/${value.job}/prometheus";
40 - static_configs = [
41 - {
42 - labels = {
43 - current = if value.status != "unmaintained" then "1" else "0";
44 - channel = name;
45 - };
46 - targets = [ "hydra.nixos.org:443" ];
47 - }
48 - ];
49 - }) (import ../../../../channels.nix).channels;
47 + ];
48 + }) (import ../../../../channels.nix).channels;
49 }
non-critical-infra/modules/limesurvey.nix
+3 -3
@@ -342,7 +342,8 @@ in
342 settings = {
343 "listen.owner" = config.services.nginx.user;
344 "listen.group" = config.services.nginx.group;
345 - } // cfg.poolConfig;
345 + }
346 + // cfg.poolConfig;
347 };
348 systemd.services.phpfpm-limesurvey.serviceConfig = {
349 ExecStartPre = pkgs.writeShellScript "limesurvey-phpfpm-exec-pre" ''
@@ -433,8 +434,7 @@ in
434 };
435
436 systemd.services.nginx.after =
436 - optional mysqlLocal "mysql.service"
437 - ++ optional pgsqlLocal "postgresql.service";
437 + optional mysqlLocal "mysql.service" ++ optional pgsqlLocal "postgresql.service";
438
439 users.users.${user} = {
440 group = group;