modules/searx: add package option (#22636)
The user should be able to specify a patched version of searx.
commited8a0d8e5e1b1de29db72373471b201b69865812
authorProfpatsch <mail@profpatsch.de>
dateFri 10 Feb 2017, 22:44 (10 years ago)
parent1b1138d
nixos/modules/services/networking/searx.nix+7−3
@@ -34,6 +34,11 @@ in
3434 ";
3535 };
3636
37+ package = mkOption {
38+ default = pkgs.pythonPackages.searx;
39+ description = "searx package to use.";
40+ };
41+
3742 };
3843
3944 };
@@ -61,14 +66,13 @@ in
6166 wantedBy = [ "multi-user.target" ];
6267 serviceConfig = {
6368 User = "searx";
64− ExecStart = "${pkgs.pythonPackages.searx}/bin/searx-run";
69+ ExecStart = "${cfg.package}/bin/searx-run";
6570 };
6671 } // (optionalAttrs (configFile != "") {
6772 environment.SEARX_SETTINGS_PATH = configFile;
6873 });
69−
7074
71− environment.systemPackages = [ pkgs.pythonPackages.searx ];
75+ environment.systemPackages = [ cfg.package ];
7276
7377 };
7478