diff --git a/hosts/ami/forgejo.nix b/hosts/ami/forgejo.nix index 4a856cd..f8ad7c0 100644 --- a/hosts/ami/forgejo.nix +++ b/hosts/ami/forgejo.nix @@ -16,7 +16,23 @@ in { HTTP_PORT = port; }; - service.DISABLE_REGISTRATION = true; + "markup.asciidoc" = { + ENABLED = true; + NEED_POSTPROCESS = true; + FILE_EXTENSIONS = ".adoc,.asciidoc"; + RENDER_COMMAND = ''"${pkgs.asciidoctor}/bin/asciidoctor -e --safe-mode=secure -a showtitle --out-file=- -"''; + IS_INPUT_FILE = false; + }; + + "markup.restructuredtext" = { + ENABLED = true; + NEED_POSTPROCESS = true; + FILE_EXTENSIONS = ".rst"; + RENDER_COMMAND = ''"timeout 30s ${pkgs.pandoc}/bin/pandoc +RTS -M512M -RTS -f rst"''; + IS_INPUT_FILE = false; + }; + + service.REGISTER_MANUAL_CONFIRM = true; cron.ENABLED = true; federation.ENABLED = true; };