mirror of
https://github.com/gensokyo-zone/infrastructure.git
synced 2026-02-09 12:29:19 -08:00
fix(monitoring): loki grpc port
This commit is contained in:
parent
3f33177ae5
commit
c8e5c6f4bf
2 changed files with 29 additions and 4 deletions
|
|
@ -139,11 +139,33 @@ in
|
|||
assertion = config.ports.default.port == nixosConfig.services.loki.settings.httpListenPort;
|
||||
message = "port mismatch";
|
||||
})
|
||||
(nixosConfig: let
|
||||
inherit (nixosConfig.services.loki.settings) grpcListenPort;
|
||||
in {
|
||||
assertion = !config.ports.grpc.enable || config.ports.grpc.port == grpcListenPort;
|
||||
message = "gRPC port mismatch";
|
||||
})
|
||||
(nixosConfig: let
|
||||
inherit (nixosConfig.services.loki.settings) grpcListenPort;
|
||||
in {
|
||||
assertion = if config.ports.grpc.enable
|
||||
then grpcListenPort != 0
|
||||
else grpcListenPort == 0;
|
||||
message = "gRPC enable mismatch";
|
||||
})
|
||||
];
|
||||
};
|
||||
ports.default = mapAlmostOptionDefaults {
|
||||
port = 9093;
|
||||
protocol = "http";
|
||||
ports = {
|
||||
default = mapAlmostOptionDefaults {
|
||||
port = 9093;
|
||||
protocol = "http";
|
||||
};
|
||||
grpc = mapAlmostOptionDefaults {
|
||||
enable = false;
|
||||
port = 9095;
|
||||
protocol = "http";
|
||||
};
|
||||
#grpclb.port = 9096;
|
||||
};
|
||||
};
|
||||
promtail = {config, ...}: {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue