mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-07-13 21:50:33 +03:00
miniflux: Add package option
This commit is contained in:
parent
20620ad867
commit
b2742248e8
1 changed files with 9 additions and 2 deletions
|
@ -21,6 +21,13 @@ in
|
||||||
services.miniflux = {
|
services.miniflux = {
|
||||||
enable = mkEnableOption (lib.mdDoc "miniflux and creates a local postgres database for it");
|
enable = mkEnableOption (lib.mdDoc "miniflux and creates a local postgres database for it");
|
||||||
|
|
||||||
|
package = mkOption {
|
||||||
|
type = types.package;
|
||||||
|
default = pkgs.miniflux;
|
||||||
|
defaultText = literalExpression "pkgs.miniflux";
|
||||||
|
description = lib.mdDoc "Miniflux package to use.";
|
||||||
|
};
|
||||||
|
|
||||||
config = mkOption {
|
config = mkOption {
|
||||||
type = types.attrsOf types.str;
|
type = types.attrsOf types.str;
|
||||||
example = literalExpression ''
|
example = literalExpression ''
|
||||||
|
@ -89,7 +96,7 @@ in
|
||||||
after = [ "network.target" "postgresql.service" "miniflux-dbsetup.service" ];
|
after = [ "network.target" "postgresql.service" "miniflux-dbsetup.service" ];
|
||||||
|
|
||||||
serviceConfig = {
|
serviceConfig = {
|
||||||
ExecStart = "${pkgs.miniflux}/bin/miniflux";
|
ExecStart = "${cfg.package}/bin/miniflux";
|
||||||
User = dbUser;
|
User = dbUser;
|
||||||
DynamicUser = true;
|
DynamicUser = true;
|
||||||
RuntimeDirectory = "miniflux";
|
RuntimeDirectory = "miniflux";
|
||||||
|
@ -122,6 +129,6 @@ in
|
||||||
|
|
||||||
environment = cfg.config;
|
environment = cfg.config;
|
||||||
};
|
};
|
||||||
environment.systemPackages = [ pkgs.miniflux ];
|
environment.systemPackages = [ cfg.package ];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue