1
0
Fork 0
mirror of https://github.com/NixOS/nixpkgs.git synced 2025-07-07 02:59:19 +03:00

nixos/apache-kafka: Use version-matched jre

This commit is contained in:
Sarah Brofeldt 2020-09-22 08:30:29 +02:00
parent 08ef827056
commit fd02940262
2 changed files with 23 additions and 1 deletions

View file

@ -106,6 +106,13 @@ in {
type = types.package;
};
jre = mkOption {
description = "The JRE with which to run Kafka";
default = cfg.package.passthru.jre;
defaultText = "pkgs.apacheKafka.passthru.jre";
type = types.package;
};
};
config = mkIf cfg.enable {
@ -126,7 +133,7 @@ in {
after = [ "network.target" ];
serviceConfig = {
ExecStart = ''
${pkgs.jre}/bin/java \
${cfg.jre}/bin/java \
-cp "${cfg.package}/libs/*" \
-Dlog4j.configuration=file:${logConfig} \
${toString cfg.jvmOptions} \