diff options
author | Martin Fischer <martin@push-f.com> | 2025-09-18 08:52:11 +0200 |
---|---|---|
committer | Martin Fischer <martin@push-f.com> | 2025-09-18 11:30:46 +0200 |
commit | 6f8f7239dc276479d691dcd0ffb5124bd62032ad (patch) | |
tree | fcf962ace86b2ff86cbba58166154f53c2cca8a7 /nixos/hosts/ev/miniflux.nix | |
parent | e3c0b6d6091bec87edf709c9d444c825045c8d3d (diff) |
I already had a miniflux instance a couple years ago
but accidentally dropped the database.
Diffstat (limited to 'nixos/hosts/ev/miniflux.nix')
-rw-r--r-- | nixos/hosts/ev/miniflux.nix | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/nixos/hosts/ev/miniflux.nix b/nixos/hosts/ev/miniflux.nix new file mode 100644 index 0000000..5bf1ccd --- /dev/null +++ b/nixos/hosts/ev/miniflux.nix @@ -0,0 +1,27 @@ +{ config, lib, pkgs, ... }: + +let + cfg = config.miniflux; +in +{ + options.miniflux = { + port = lib.mkOption { + type = lib.types.int; + }; + }; + + config = { + age.secrets.miniflux-admin.file = <top/secrets/miniflux-admin.age>; + + services.miniflux = { + enable = true; + config = { + LISTEN_ADDR = "0.0.0.0:${toString cfg.port}"; + DATABASE_URL = "user=miniflux host=/run/postgresql dbname=miniflux"; + }; + # miniflux does not support disabling its authentication. https://github.com/miniflux/v2/issues/408 + adminCredentialsFile = config.age.secrets.miniflux-admin.path; + createDatabaseLocally = false; + }; + }; +} |