diff options
Diffstat (limited to 'modules/private/websites/tools/git/default.nix')
-rw-r--r-- | modules/private/websites/tools/git/default.nix | 49 |
1 files changed, 0 insertions, 49 deletions
diff --git a/modules/private/websites/tools/git/default.nix b/modules/private/websites/tools/git/default.nix deleted file mode 100644 index 8f611ee..0000000 --- a/modules/private/websites/tools/git/default.nix +++ /dev/null | |||
@@ -1,49 +0,0 @@ | |||
1 | { lib, pkgs, config, ... }: | ||
2 | let | ||
3 | mantisbt = pkgs.callPackage ./mantisbt.nix { | ||
4 | inherit (pkgs.webapps) mantisbt_2 mantisbt_2-plugins; | ||
5 | env = config.myEnv.tools.mantisbt; | ||
6 | inherit config; | ||
7 | }; | ||
8 | gitweb = pkgs.callPackage ./gitweb.nix { | ||
9 | gitoliteDir = config.myServices.gitolite.gitoliteDir; | ||
10 | }; | ||
11 | |||
12 | cfg = config.myServices.websites.tools.git; | ||
13 | in { | ||
14 | options.myServices.websites.tools.git = { | ||
15 | enable = lib.mkEnableOption "enable git's website"; | ||
16 | }; | ||
17 | |||
18 | config = lib.mkIf cfg.enable { | ||
19 | secrets.keys = mantisbt.keys; | ||
20 | services.websites.env.tools.modules = | ||
21 | gitweb.apache.modules ++ | ||
22 | mantisbt.apache.modules; | ||
23 | |||
24 | system.activationScripts.mantisbt = mantisbt.activationScript; | ||
25 | services.websites.env.tools.vhostConfs.git = { | ||
26 | certName = "eldiron"; | ||
27 | addToCerts = true; | ||
28 | hosts = ["git.immae.eu" ]; | ||
29 | root = gitweb.apache.root; | ||
30 | extraConfig = [ | ||
31 | gitweb.apache.vhostConf | ||
32 | (mantisbt.apache.vhostConf config.services.phpfpm.pools.mantisbt.socket) | ||
33 | '' | ||
34 | RewriteEngine on | ||
35 | RewriteCond %{REQUEST_URI} ^/releases | ||
36 | RewriteRule /releases(.*) https://release.immae.eu$1 [P,L] | ||
37 | '' | ||
38 | ]; | ||
39 | }; | ||
40 | services.phpfpm.pools = { | ||
41 | mantisbt = { | ||
42 | user = config.services.httpd.Tools.user; | ||
43 | group = config.services.httpd.Tools.group; | ||
44 | settings = mantisbt.phpFpm.pool; | ||
45 | phpPackage = pkgs.php72; | ||
46 | }; | ||
47 | }; | ||
48 | }; | ||
49 | } | ||