1 { lib, pkgs, config, ... }:
3 cfg = config.myServices.websites.leila.production;
4 varDir = "/var/lib/ftp/leila";
6 options.myServices.websites.leila.production.enable = lib.mkEnableOption "enable Leila's websites in production";
8 config = lib.mkIf cfg.enable {
9 services.phpfpm.pools.leila = {
10 listen = "/run/phpfpm/leila.sock";
19 pm.process_idle_timeout = 60
21 php_admin_value[open_basedir] = "${varDir}:/tmp"
25 services.webstats.sites = [
26 { name = "leila.bouya.org"; }
27 { name = "chorale.leila.bouya.org"; }
28 { name = "syrwennecreation.bouya.org"; }
31 services.websites.env.production.modules = [ "proxy_fcgi" ];
32 services.websites.env.production.vhostConfs.leila_chorale = {
35 hosts = [ "chorale.leila.bouya.org" "chorale-vocanta.fr.nf" "www.chorale-vocanta.fr.nf" ];
36 root = "${varDir}/Chorale";
39 Use Stats chorale.leila.bouya.org
40 <Directory ${varDir}/Chorale>
41 DirectoryIndex index.php index.htm index.html
42 Options Indexes FollowSymLinks MultiViews Includes
46 Require ldap-group cn=chorale.leila.bouya.org,cn=httpd,ou=services,dc=immae,dc=eu
49 SetHandler "proxy:unix:/run/phpfpm/leila.sock|fcgi://localhost"
55 services.websites.env.production.vhostConfs.leila_syrwenne = {
58 hosts = [ "syrwennecreation.bouya.org" ];
59 root = "${varDir}/Syrwennecreation";
62 Use Stats syrwennecreation.bouya.org
63 <Directory ${varDir}/Syrwennecreation>
64 DirectoryIndex index.php index.htm index.html
65 Options Indexes FollowSymLinks MultiViews Includes
69 SetHandler "proxy:unix:/run/phpfpm/leila.sock|fcgi://localhost"
75 services.websites.env.production.vhostConfs.leila = {
77 certMainHost = "leila.bouya.org";
78 hosts = [ "leila.bouya.org" ];
82 Use Stats leila.bouya.org
83 <Directory ${varDir}/Chorale>
84 DirectoryIndex index.htm index.html
85 Options Indexes FollowSymLinks MultiViews Includes
89 Require ldap-group cn=chorale.leila.bouya.org,cn=httpd,ou=services,dc=immae,dc=eu
92 SetHandler "proxy:unix:/run/phpfpm/leila.sock|fcgi://localhost"
96 DirectoryIndex index.htm index.html
97 Options Indexes FollowSymLinks MultiViews Includes