mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-12-26 04:43:09 +03:00
modules/searx: add package option (#22636)
The user should be able to specify a patched version of searx.
This commit is contained in:
parent
1b1138d3e7
commit
ed8a0d8e5e
@ -34,6 +34,11 @@ in
|
|||||||
";
|
";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
package = mkOption {
|
||||||
|
default = pkgs.pythonPackages.searx;
|
||||||
|
description = "searx package to use.";
|
||||||
|
};
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
};
|
};
|
||||||
@ -61,14 +66,13 @@ in
|
|||||||
wantedBy = [ "multi-user.target" ];
|
wantedBy = [ "multi-user.target" ];
|
||||||
serviceConfig = {
|
serviceConfig = {
|
||||||
User = "searx";
|
User = "searx";
|
||||||
ExecStart = "${pkgs.pythonPackages.searx}/bin/searx-run";
|
ExecStart = "${cfg.package}/bin/searx-run";
|
||||||
};
|
};
|
||||||
} // (optionalAttrs (configFile != "") {
|
} // (optionalAttrs (configFile != "") {
|
||||||
environment.SEARX_SETTINGS_PATH = configFile;
|
environment.SEARX_SETTINGS_PATH = configFile;
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
environment.systemPackages = [ pkgs.pythonPackages.searx ];
|
environment.systemPackages = [ cfg.package ];
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user