forked from mirrors/nixpkgs
nixos/goeland: init
This commit is contained in:
parent
8434981633
commit
988feead01
|
@ -83,6 +83,14 @@
|
||||||
<link xlink:href="options.html#opt-networking.stevenblack.enable">networking.stevenblack</link>.
|
<link xlink:href="options.html#opt-networking.stevenblack.enable">networking.stevenblack</link>.
|
||||||
</para>
|
</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
|
<listitem>
|
||||||
|
<para>
|
||||||
|
<link xlink:href="https://github.com/slurdge/goeland">goeland</link>,
|
||||||
|
an alternative to rss2email written in golang with many
|
||||||
|
filters. Available as
|
||||||
|
<link linkend="opt-services.goeland.enable">services.goeland</link>.
|
||||||
|
</para>
|
||||||
|
</listitem>
|
||||||
<listitem>
|
<listitem>
|
||||||
<para>
|
<para>
|
||||||
<link xlink:href="https://github.com/ellie/atuin">atuin</link>,
|
<link xlink:href="https://github.com/ellie/atuin">atuin</link>,
|
||||||
|
|
|
@ -30,6 +30,8 @@ In addition to numerous new and upgraded packages, this release has the followin
|
||||||
|
|
||||||
- [stevenblack-blocklist](https://github.com/StevenBlack/hosts), A unified hosts file with base extensions for blocking unwanted websites. Available as [networking.stevenblack](options.html#opt-networking.stevenblack.enable).
|
- [stevenblack-blocklist](https://github.com/StevenBlack/hosts), A unified hosts file with base extensions for blocking unwanted websites. Available as [networking.stevenblack](options.html#opt-networking.stevenblack.enable).
|
||||||
|
|
||||||
|
- [goeland](https://github.com/slurdge/goeland), an alternative to rss2email written in golang with many filters. Available as [services.goeland](#opt-services.goeland.enable).
|
||||||
|
|
||||||
- [atuin](https://github.com/ellie/atuin), a sync server for shell history. Available as [services.atuin](#opt-services.atuin.enable).
|
- [atuin](https://github.com/ellie/atuin), a sync server for shell history. Available as [services.atuin](#opt-services.atuin.enable).
|
||||||
|
|
||||||
- [mmsd](https://gitlab.com/kop316/mmsd), a lower level daemon that transmits and recieves MMSes. Available as [services.mmsd](#opt-services.mmsd.enable).
|
- [mmsd](https://gitlab.com/kop316/mmsd), a lower level daemon that transmits and recieves MMSes. Available as [services.mmsd](#opt-services.mmsd.enable).
|
||||||
|
|
|
@ -530,6 +530,7 @@
|
||||||
./services/mail/dovecot.nix
|
./services/mail/dovecot.nix
|
||||||
./services/mail/dspam.nix
|
./services/mail/dspam.nix
|
||||||
./services/mail/exim.nix
|
./services/mail/exim.nix
|
||||||
|
./services/mail/goeland.nix
|
||||||
./services/mail/listmonk.nix
|
./services/mail/listmonk.nix
|
||||||
./services/mail/maddy.nix
|
./services/mail/maddy.nix
|
||||||
./services/mail/mail.nix
|
./services/mail/mail.nix
|
||||||
|
|
58
nixos/modules/services/mail/goeland.nix
Normal file
58
nixos/modules/services/mail/goeland.nix
Normal file
|
@ -0,0 +1,58 @@
|
||||||
|
{ config, lib, pkgs, ... }:
|
||||||
|
|
||||||
|
with lib;
|
||||||
|
|
||||||
|
let
|
||||||
|
cfg = config.services.goeland;
|
||||||
|
tomlFormat = pkgs.formats.toml { };
|
||||||
|
in
|
||||||
|
{
|
||||||
|
options.services.goeland = {
|
||||||
|
enable = mkEnableOption (mdDoc "goeland");
|
||||||
|
|
||||||
|
settings = mkOption {
|
||||||
|
description = mdDoc ''
|
||||||
|
Configuration of goeland.
|
||||||
|
See the [example config file](https://github.com/slurdge/goeland/blob/master/cmd/asset/config.default.toml) for the available options.
|
||||||
|
'';
|
||||||
|
default = { };
|
||||||
|
type = types.submodule {
|
||||||
|
freeformType = tomlFormat.type;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
schedule = mkOption {
|
||||||
|
type = types.str;
|
||||||
|
default = "12h";
|
||||||
|
example = "Mon, 00:00:00";
|
||||||
|
description = mdDoc "How often to run goeland, in systemd time format";
|
||||||
|
};
|
||||||
|
databaseDirectory = mkOption {
|
||||||
|
type = types.path;
|
||||||
|
default = "/var/lib/goeland";
|
||||||
|
description = mdDoc "Directory where the goeland database will reside if using the `unseen` filter";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
config = mkIf cfg.enable {
|
||||||
|
systemd.tmpfiles.rules = [ "d ${cfg.databaseDirectory} 0750 goeland goeland -" ];
|
||||||
|
|
||||||
|
services.goeland.settings.database = "${cfg.databaseDirectory}/goeland.db";
|
||||||
|
|
||||||
|
systemd.services.goeland = {
|
||||||
|
serviceConfig = let confFile = tomlFormat.generate "config.toml" cfg.settings; in {
|
||||||
|
ExecStart = "${pkgs.goeland}/bin/goeland run -c ${confFile}";
|
||||||
|
User = "goeland";
|
||||||
|
};
|
||||||
|
startAt = cfg.schedule;
|
||||||
|
};
|
||||||
|
|
||||||
|
users.users.goeland = {
|
||||||
|
description = "goeland user";
|
||||||
|
group = "goeland";
|
||||||
|
isSystemUser = true;
|
||||||
|
};
|
||||||
|
users.groups.goeland = { };
|
||||||
|
};
|
||||||
|
|
||||||
|
meta.maintainers = with maintainers; [ sweenu ];
|
||||||
|
}
|
|
@ -23,14 +23,15 @@ buildGoModule rec {
|
||||||
];
|
];
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
description = "An alternative to RSS2Email written in golang with many filters.";
|
description = "An alternative to rss2email written in golang with many filters";
|
||||||
longDescription = ''
|
longDescription = ''
|
||||||
Goeland excels at creating beautiful emails from RSS,
|
Goeland excels at creating beautiful emails from RSS feeds,
|
||||||
tailored for daily or weekly digest. It include a number of
|
tailored for daily or weekly digest. It includes a number of
|
||||||
filters that can transform the RSS content along the way.
|
filters that can transform the RSS content along the way.
|
||||||
It can also consume other sources, such as a Imgur tag.
|
It can also consume other sources, such as Imgur tags.
|
||||||
'';
|
'';
|
||||||
homepage = "https://github.com/slurdge/goeland";
|
homepage = "https://github.com/slurdge/goeland";
|
||||||
|
changelog = "https://github.com/slurdge/goeland/blob/v${version}/CHANGELOG.md";
|
||||||
license = with licenses; [ mit ];
|
license = with licenses; [ mit ];
|
||||||
maintainers = [ maintainers.sweenu ];
|
maintainers = [ maintainers.sweenu ];
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue