Home

infra @9eac237b3403689f939e0820ba810cf376638f65 - refs - log -
-
https://git.jolheiser.com/infra.git
dragonwell flake
infra / dragonwell / mealie.nix
- raw -
 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
27
28
29
30
{ pkgs, config, ... }:
let
  port = 3663;
in
{
  age.secrets.mealie.file = ../secrets/mealie.age;
  services = {
    mealie = {
      enable = true;
      # TODO remove this hack once mealie tests work again
      package = pkgs.mealie.overrideAttrs (
        _: _: {
          doCheck = false;
          checkPhase = ''echo "Skipping tests for mealie"'';
          installCheckPhase = ''echo "Skipping install tests for mealie"'';
        }
      );
      listenAddress = "localhost";
      inherit port;
      settings = {
        BASE_URL = "https://recipes.jolheiser.com";
        ALLOW_PASSWORD_LOGIN = "false";
      };
      credentialsFile = config.age.secrets.mealie.path;
    };
    caddy.virtualHosts."recipes.jolheiser.com".extraConfig = ''
      reverse_proxy localhost:${builtins.toString port}
    '';
  };
}