]>
Commit | Line | Data |
---|---|---|
f8026b6e IB |
1 | { lib, pkgs, config, myconfig, ... }: |
2 | let | |
3 | ludivinecassal = pkgs.callPackage ./builder.nix { | |
4 | inherit (pkgs.webapps) ludivinecassal; | |
5 | config = myconfig.env.websites.ludivinecassal.integration; | |
6 | apacheUser = config.services.httpd.Inte.user; | |
7 | apacheGroup = config.services.httpd.Inte.group; | |
8 | }; | |
9 | ||
10 | cfg = config.myServices.websites.ludivinecassal.integration; | |
11 | in { | |
12 | options.myServices.websites.ludivinecassal.integration.enable = lib.mkEnableOption "enable Ludivine's website in integration"; | |
13 | ||
14 | config = lib.mkIf cfg.enable { | |
15 | secrets.keys = ludivinecassal.keys; | |
16 | ||
17 | services.myPhpfpm.preStart.ludivinecassal_dev = ludivinecassal.phpFpm.preStart; | |
18 | services.myPhpfpm.serviceDependencies.ludivinecassal_dev = ludivinecassal.phpFpm.serviceDeps; | |
19 | services.myPhpfpm.poolConfigs.ludivinecassal_dev = ludivinecassal.phpFpm.pool; | |
20 | system.activationScripts.ludivinecassal_dev = ludivinecassal.activationScript; | |
21 | system.extraSystemBuilderCmds = '' | |
22 | mkdir -p $out/webapps | |
23 | ln -s ${ludivinecassal.app.webRoot} $out/webapps/${ludivinecassal.apache.webappName} | |
24 | ''; | |
25 | services.websites.integration.modules = ludivinecassal.apache.modules; | |
26 | services.websites.integration.vhostConfs.ludivine = { | |
27 | certName = "eldiron"; | |
28 | addToCerts = true; | |
29 | hosts = [ "ludivine.immae.eu" ]; | |
30 | root = ludivinecassal.apache.root; | |
31 | extraConfig = [ ludivinecassal.apache.vhostConf ]; | |
32 | }; | |
33 | }; | |
34 | } |