Skip to content

Commit 1146c44

Browse files
committed
grafana-loki, promtail: move to by-name
1 parent efbd3b0 commit 1146c44

File tree

3 files changed

+34
-24
lines changed

3 files changed

+34
-24
lines changed

pkgs/servers/monitoring/loki/default.nix renamed to pkgs/by-name/gr/grafana-loki/package.nix

Lines changed: 34 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,13 @@
1-
{ stdenv
2-
, lib
3-
, buildGoModule
4-
, fetchFromGitHub
5-
, makeWrapper
6-
, nixosTests
7-
, systemd
8-
, testers
9-
, grafana-loki
1+
{
2+
stdenv,
3+
lib,
4+
buildGoModule,
5+
fetchFromGitHub,
6+
makeWrapper,
7+
nixosTests,
8+
systemd,
9+
testers,
10+
grafana-loki,
1011
}:
1112

1213
buildGoModule rec {
@@ -31,7 +32,7 @@ buildGoModule rec {
3132
"cmd/lokitool"
3233
];
3334

34-
tags = ["promtail_journal_enabled"];
35+
tags = [ "promtail_journal_enabled" ];
3536

3637
nativeBuildInputs = [ makeWrapper ];
3738
buildInputs = lib.optionals stdenv.hostPlatform.isLinux [ systemd.dev ];
@@ -49,22 +50,34 @@ buildGoModule rec {
4950
};
5051
};
5152

52-
ldflags = let t = "github.com/grafana/loki/v3/pkg/util/build"; in [
53-
"-s"
54-
"-w"
55-
"-X ${t}.Version=${version}"
56-
"-X ${t}.BuildUser=nix@nixpkgs"
57-
"-X ${t}.BuildDate=unknown"
58-
"-X ${t}.Branch=unknown"
59-
"-X ${t}.Revision=unknown"
60-
];
53+
ldflags =
54+
let
55+
t = "github.com/grafana/loki/v3/pkg/util/build";
56+
in
57+
[
58+
"-s"
59+
"-w"
60+
"-X ${t}.Version=${version}"
61+
"-X ${t}.BuildUser=nix@nixpkgs"
62+
"-X ${t}.BuildDate=unknown"
63+
"-X ${t}.Branch=unknown"
64+
"-X ${t}.Revision=unknown"
65+
];
6166

6267
meta = with lib; {
6368
description = "Like Prometheus, but for logs";
6469
mainProgram = "promtail";
65-
license = with licenses; [ agpl3Only asl20 ];
70+
license = with licenses; [
71+
agpl3Only
72+
asl20
73+
];
6674
homepage = "https://grafana.com/oss/loki/";
6775
changelog = "https://github.com/grafana/loki/releases/tag/v${version}";
68-
maintainers = with maintainers; [ willibutz globin mmahut emilylange ];
76+
maintainers = with maintainers; [
77+
willibutz
78+
globin
79+
mmahut
80+
emilylange
81+
];
6982
};
7083
}
File renamed without changes.

pkgs/top-level/all-packages.nix

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11261,9 +11261,6 @@ with pkgs;
1126111261
grafana = callPackage ../servers/monitoring/grafana { };
1126211262
grafanaPlugins = callPackages ../servers/monitoring/grafana/plugins { };
1126311263

11264-
grafana-loki = callPackage ../servers/monitoring/loki { };
11265-
promtail = callPackage ../servers/monitoring/loki/promtail.nix { };
11266-
1126711264
hasura-graphql-engine = haskell.lib.compose.justStaticExecutables haskell.packages.ghc810.graphql-engine;
1126811265

1126911266
hasura-cli = callPackage ../servers/hasura/cli.nix { };

0 commit comments

Comments
 (0)