1 { lib, phpbb, gnused }:
3 varDir = "/var/lib/phpbb";
7 if [ ! -d ${varDir} ]; then
8 install -m 0755 -o ${apache.user} -g ${apache.user} -d ${varDir}
9 cp -a ${phpbb}/vars/* ${varDir}
10 chown -R ${apache.user}:${apache.user} ${varDir}
12 install -m 0750 -o ${apache.user} -g ${apache.group} -d ${varDir}/phpSessions
19 modules = [ "proxy_fcgi" ];
21 vhostConf = socket: ''
22 Alias /forum "${root}"
24 DirectoryIndex index.php
26 SetHandler "proxy:unix:${socket}|fcgi://localhost"
30 Options FollowSymlinks
33 # add instal to the list after install
34 <LocationMatch "^/(cache|files|install|store)>
40 serviceDeps = [ "postgresql.service" ];
41 basedir = builtins.concatStringsSep ":" [ "/run/wrappers/bin/sendmail" phpbb varDir ];
43 "listen.owner" = apache.user;
44 "listen.group" = apache.group;
46 "pm.max_children" = "60";
47 "pm.process_idle_timeout" = "60";
49 # Needed to avoid clashes in browser cookies (same domain)
50 "php_value[session.name]" = "PhpBBPHPSESSID";
51 "php_admin_value[open_basedir]" = "${basedir}:/tmp";
52 "php_admin_value[session.save_path]" = "${varDir}/phpSessions";