2022-09-23 01:10:50 -07:00
|
|
|
{ pkgs, config, lib, ... }:
|
|
|
|
|
|
|
|
{
|
|
|
|
services.paperless = {
|
2023-05-15 07:20:26 -07:00
|
|
|
enable = false;
|
2022-09-26 06:27:31 -07:00
|
|
|
consumptionDirIsPublic = true;
|
2024-08-19 21:29:41 -07:00
|
|
|
settings.PAPERLESS_AUTO_LOGIN_USERNAME = "admin";
|
2022-09-23 01:10:50 -07:00
|
|
|
};
|
|
|
|
|
|
|
|
environment.systemPackages = [
|
2022-09-26 06:27:31 -07:00
|
|
|
pkgs.beancount
|
2022-09-23 01:10:50 -07:00
|
|
|
];
|
|
|
|
|
2022-09-26 06:27:31 -07:00
|
|
|
# TODO
|
|
|
|
# This one doesn't have a start condition, so I'm manually triggering it
|
|
|
|
# I'm not sure what the proper start condition is for it
|
|
|
|
systemd.services.fava = {
|
|
|
|
path = [
|
|
|
|
pkgs.fava
|
|
|
|
];
|
2023-05-15 07:20:26 -07:00
|
|
|
wantedBy = [ "multi-user.target" ];
|
2022-09-26 06:27:31 -07:00
|
|
|
before = [ "nginx.service" ];
|
|
|
|
serviceConfig = {
|
|
|
|
User = "anish";
|
|
|
|
ExecStart = ''
|
|
|
|
${pkgs.fava}/bin/fava -p 29492 /home/anish/usr/finance/ledger.beancount
|
|
|
|
'';
|
|
|
|
Restart = "on-failure";
|
|
|
|
};
|
|
|
|
};
|
2022-09-23 01:10:50 -07:00
|
|
|
|
|
|
|
services.nginx = {
|
|
|
|
enable = true;
|
|
|
|
virtualHosts."fin.mossnet.lan".locations."/" = {
|
2022-09-26 06:27:31 -07:00
|
|
|
proxyPass = "http://localhost:29492";
|
|
|
|
};
|
|
|
|
virtualHosts."paper.mossnet.lan".locations."/" = {
|
2022-09-23 01:10:50 -07:00
|
|
|
proxyPass = "http://localhost:28981";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|