nix/modules/nixos/services/gotenberg/default.nix
Ameya Shenoy 4998e822a7 feat: init
Signed-off-by: Ameya Shenoy <shenoy.ameya@gmail.com>
2024-11-11 01:48:40 +05:30

26 lines
823 B
Nix

{ config, lib, pkgs, ... }: {
options.snowflake.services.gotenberg = {
enable = lib.mkEnableOption "enable gotenberg";
};
config = lib.mkIf config.snowflake.services.gotenberg.enable {
# gottenberg systemctl service is failing for some reason
# running the Exec function manually works, however the service fails
# need to debug deeper
services.gotenberg = {
enable = true;
port = 3000;
chromium.package = pkgs.ungoogled-chromium;
chromium.disableJavascript = true;
libreoffice.package = pkgs.libreoffice;
logLevel = "debug";
# this doesn't work: https://github.com/NixOS/nixpkgs/issues/340447
extraArgs = [ "--chromium-allow-list=file:///tmp/.*" ];
};
environment.systemPackages = with pkgs; [ ungoogled-chromium libreoffice ];
};
}