summaryrefslogtreecommitdiff
path: root/systems/atlas/miniflux.nix
blob: 884cf7afb26a9217f333810a466a69233df7b4f6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
{ config, secretsDir, ... }:

{
  age.secrets.miniflux.file = secretsDir + "/miniflux.age";

  services = {
    miniflux = {
      enable = true;
      adminCredentialsFile = config.age.secrets.miniflux.path;
      config = {
        BASE_URL = "https://miniflux.${config.networking.domain}";
        LISTEN_ADDR = "/run/miniflux";
      };
    };

    nginx = {
      virtualHosts = {
        "miniflux.getchoo.com" = {
          locations."/" = {
            proxyPass = "http://unix:${config.services.miniflux.config.LISTEN_ADDR}";
          };
        };
      };
    };
  };
}