diff options
Diffstat (limited to 'modules')
-rw-r--r-- | modules/hledger-web.nix | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/modules/hledger-web.nix b/modules/hledger-web.nix index 57faed6..bfe5e24 100644 --- a/modules/hledger-web.nix +++ b/modules/hledger-web.nix @@ -37,5 +37,18 @@ in { hledger-web -f ${cfg.journalFile} --auto --port ${cfg.port} ''; }; + + services.nginx.virtualHosts."money.orbekk.com" = { + enableACME = true; + forceSSL = true; + locations."/" = { + proxyPass = "http://127.0.0.1:${toString cfg.port}"; + proxyWebsockets = true; + extraConfig = '' + auth_basic money; + auth_basic_user_file "/opt/secret/nginx-money.htpasswd"; + ''; + }; + }; }; } |