summaryrefslogtreecommitdiff
path: root/manifests
diff options
context:
space:
mode:
authormh <mh@immerda.ch>2011-10-08 23:53:15 +0200
committermh <mh@immerda.ch>2011-10-08 23:53:15 +0200
commitc7176c592622f3bc6955f36d359252e55c4e3d8d (patch)
treea46cfc832548799e730d1050c6415f7a79b7028f /manifests
parent968676d43da076d4ecc9d33c4a5f8a2fb532285c (diff)
log php errors to a per vhost logfile
Diffstat (limited to 'manifests')
-rw-r--r--manifests/vhost/php/standard.pp8
1 files changed, 8 insertions, 0 deletions
diff --git a/manifests/vhost/php/standard.pp b/manifests/vhost/php/standard.pp
index 7de2798..077bde4 100644
--- a/manifests/vhost/php/standard.pp
+++ b/manifests/vhost/php/standard.pp
@@ -92,6 +92,10 @@ define apache::vhost::php::standard(
} else {
$documentroot = "${real_path}/www"
}
+ $logdir = $logpath ? {
+ 'absent' => "$real_path/logs",
+ default => $logpath
+ }
$std_php_options = {
smarty => false,
@@ -120,6 +124,9 @@ define apache::vhost::php::standard(
open_basedir => "${smarty_path}${pear_path}${documentroot}:/var/www/upload_tmp_dir/${name}:/var/www/session.save_path/${name}",
safe_mode => 'On',
}
+ if $logmode != 'nologs' {
+ $std_php_settings[error_log] = "${logdir}/php_error_log"
+ }
if has_key($php_settings,'safe_mode_exec_dir') {
$php_safe_mode_exec_dir = $php_settings[safe_mode_exec_dir]
@@ -178,6 +185,7 @@ define apache::vhost::php::standard(
'fcgid': {
include ::mod_fcgid
include ::php::mod_fcgid
+
mod_fcgid::starter {$name:
cgi_type => 'php',
cgi_type_options => $real_php_settings,