Added perl modules needed by smbldap-tools to SAMBA.samba-ldap.choice
[mnemosyne.git] / pkg_conf / php.conf
blob817e1f1faeb132bffc1fad9b068125c6f2329cce
1 # --- SDE-COPYRIGHT-NOTE-BEGIN ---
2 # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
3
4 # Filename: target/mnemosyne/pkg_conf/php.conf
5 # Copyright (C) 2006 The OpenSDE Project
6 # Copyright (C) 2002 - 2006 Alejandro Mery
7
8 # More information can be found in the files COPYING and README.
9
10 # This program is free software; you can redistribute it and/or modify
11 # it under the terms of the GNU General Public License as published by
12 # the Free Software Foundation; version 2 of the License. A copy of the
13 # GNU General Public License can be found in the file COPYING.
14 # --- SDE-COPYRIGHT-NOTE-END ---
16 case "$SDECFG_TRG_MNEMOSYNE_WEB" in
17 apache)
18         pkgprefix -t apache
19         hook_add postmake 5 "mnemosyne_php_addconf $( pkgprefix sysconfdir apache )"
21         mnemosyne_php_addconf() {
22                 mkdir -p $1/conf.d
23                 cat <<-EOT > $1/conf.d/php.conf
24                 LoadModule php5_module modules/libphp5.so
26                 AddHandler application/x-httpd-php .php
27                 EOT
28         }
29         ;;
31 lighttpd)
32         pkgprefix -t lighttpd
33         hook_add postmake 7 "mnemosyne_php_addconf $( pkgprefix sysconfdir lighttpd )"
35         mnemosyne_php_addconf() {
36                 cat <<-EOT >> $root$1/conf.d/php.conf-dist
37                 fastcgi.server = ( ".php" =>
38                    (( "socket" => "/tmp/php-fastcgi.socket",
39                       "bin-path" => "$bindir/php",
40                       "max-procs" => 1,
41                       "bin-environment" => ( 
42                         "PHP_FCGI_CHILDREN" => "16",
43                         "PHP_FCGI_MAX_REQUESTS" => "10000" ),
44                       "bin-copy-environment" => (
45                         "PATH", "SHELL", "USER" )
46                    ))
47                 )
48                 EOT
49         }
50         ;;
51 esac