1 { lib, pkgs, config, ... }:
3 mantisbt = pkgs.callPackage ./mantisbt.nix {
4 mantisbt_2 = pkgs.webapps-mantisbt_2;
5 mantisbt_2-plugins = pkgs.webapps-mantisbt_2-plugins;
6 env = config.myEnv.tools.mantisbt;
9 gitweb = pkgs.callPackage ./gitweb.nix {
10 gitoliteDir = config.myServices.gitolite.gitoliteDir;
13 cfg = config.myServices.websites.tools.git;
15 options.myServices.websites.tools.git = {
16 enable = lib.mkEnableOption "enable git's website";
19 config = lib.mkIf cfg.enable {
20 myServices.chatonsProperties.services.mantisbt = {
21 file.datetime = "2022-08-21T10:08:00";
24 description = "Mantis Bug Tracker";
25 website = "https://git.immae.eu/mantisbt";
26 logo = "https://git.immae.eu/mantisbt/images/favicon.ico";
28 status.description = "OK";
29 registration."" = ["MEMBER" "CLIENT"];
30 registration.load = "OPEN";
31 install.type = "PACKAGE";
32 guide.user = "https://www.immae.eu/docs/forge-logicielle.html";
36 website = "https://mantisbt.org/";
37 license.url = "https://opensource.org/licenses/gpl-license";
38 license.name = "GNU General Public License";
39 version = mantisbt.webRoot.version;
40 source.url = "https://github.com/mantisbt/mantisbt";
41 modules = mantisbt.webRoot.pluginNames;
44 secrets.keys = mantisbt.keys;
45 services.websites.env.tools.modules =
46 gitweb.apache.modules ++
47 mantisbt.apache.modules;
49 security.acme.certs.eldiron.extraDomainNames = [ "git.immae.eu" ];
50 services.websites.env.tools.vhostConfs.git = {
52 hosts = ["git.immae.eu" ];
53 root = gitweb.apache.root;
55 gitweb.apache.vhostConf
56 (mantisbt.apache.vhostConf config.services.phpfpm.pools.mantisbt.socket)
59 RewriteCond %{REQUEST_URI} ^/releases
60 RewriteRule /releases(.*) https://release.immae.eu$1 [P,L]
64 services.phpfpm.pools = {
66 user = config.services.websites.env.tools.user;
67 group = config.services.websites.env.tools.group;
68 settings = mantisbt.phpFpm.pool;
69 phpPackage = pkgs.php72.withExtensions({ enabled, all }: enabled ++ [all.redis]);
73 myServices.monitoring.fromMasterActivatedPlugins = [ "http" ];
74 myServices.monitoring.fromMasterObjects.service = [
76 service_description = "gitweb website is running on git.immae.eu";
77 host_name = config.hostEnv.fqdn;
78 use = "external-web-service";
79 check_command = ["check_https" "git.immae.eu" "/cgit" "<title>Immae’s git"];
81 servicegroups = "webstatus-webapps";
82 _webstatus_name = "Git";
83 _webstatus_url = "https://git.immae.eu/";
87 service_description = "mantisbt website is running on git.immae.eu";
88 host_name = config.hostEnv.fqdn;
89 use = "external-web-service";
90 check_command = ["check_https" "git.immae.eu" "/mantisbt/" "<title>My View - MantisBT"];
92 servicegroups = "webstatus-webapps";
93 _webstatus_name = "Mantisbt";
94 _webstatus_url = "https://git.immae.eu/mantisbt";