X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=systems%2Feldiron%2Fwebsites%2Fgit%2Fmantisbt.nix;fp=systems%2Feldiron%2Fwebsites%2Fgit%2Fmantisbt.nix;h=3bd78e13980f31212655c5ca1e9953bca82025c2;hb=1a64deeb894dc95e2645a75771732c6cc53a79ad;hp=0000000000000000000000000000000000000000;hpb=fa25ffd4583cc362075cd5e1b4130f33306103f0;p=perso%2FImmae%2FConfig%2FNix.git diff --git a/systems/eldiron/websites/git/mantisbt.nix b/systems/eldiron/websites/git/mantisbt.nix new file mode 100644 index 0000000..3bd78e1 --- /dev/null +++ b/systems/eldiron/websites/git/mantisbt.nix @@ -0,0 +1,86 @@ +{ env, mantisbt_2, mantisbt_2-plugins, config }: +rec { + keys."webapps/tools-mantisbt" = { + user = apache.user; + group = apache.group; + permissions = "0400"; + text = '' + + DirectoryIndex index.php + + SetHandler "proxy:unix:${socket}|fcgi://localhost" + + + AllowOverride All + SetEnvIf Authorization "(.*)" HTTP_AUTHORIZATION=$1 + Options FollowSymlinks + Require all granted + + + #Reenable during upgrade + Require all denied + + ''; + }; + phpFpm = rec { + serviceDeps = [ "postgresql.service" "openldap.service" ]; + basedir = builtins.concatStringsSep ":" ( + [ webRoot config.secrets.fullPaths."webapps/tools-mantisbt" ] + ++ webRoot.plugins); + pool = { + "listen.owner" = apache.user; + "listen.group" = apache.group; + "pm" = "ondemand"; + "pm.max_children" = "60"; + "pm.process_idle_timeout" = "60"; + + "php_admin_value[upload_max_filesize]" = "5000000"; + + "php_admin_value[open_basedir]" = "${basedir}:/tmp"; + "php_admin_value[session.save_handler]" = "redis"; + "php_admin_value[session.save_path]" = "'unix:///run/redis-php-sessions/redis.sock?persistent=1&prefix=Tools:MantisBT:'"; + }; + }; +}