apache: Fix fcgid on CentOS, dependency fix for wsgi

Create separate mod_fcgid socket dirs for http and httpsd. Also tune the
process limits.
This commit is contained in:
Ossi Salmi 2013-06-16 01:42:13 +03:00
parent 1fbaaacc65
commit fc12e7e03e
4 changed files with 52 additions and 6 deletions

View file

@ -0,0 +1,11 @@
LoadModule fcgid_module modules/mod_fcgid.so
AddHandler fcgid-script fcg fcgi fpl
FcgidIPCDir /var/run/mod_fcgid
FcgidProcessTableFile /var/run/mod_fcgid/fcgid_shm
FcgidMinProcessesPerClass 0
FcgidMaxProcessesPerClass 5
FcgidMaxRequestLen 16777216
FcgidPassHeader Authorization

View file

@ -0,0 +1,11 @@
LoadModule fcgid_module modules/mod_fcgid.so
AddHandler fcgid-script fcg fcgi fpl
FcgidIPCDir /var/run/mod_fcgid_httpsd
FcgidProcessTableFile /var/run/mod_fcgid_httpsd/fcgid_shm
FcgidMinProcessesPerClass 0
FcgidMaxProcessesPerClass 5
FcgidMaxRequestLen 16777216
FcgidPassHeader Authorization

View file

@ -468,8 +468,31 @@ class apache::mod::fcgid {
} }
} }
"centos","redhat","fedora": { "centos","redhat","fedora": {
apache::configfile { "fcgid.conf": if defined(Class["apache::server"]) {
require => Package["mod_fcgid"], file { "/var/run/mod_fcgid":
ensure => directory,
mode => "0755",
owner => $apache::server::user,
group => $apache::server::group,
before => Service["httpd"],
}
apache::configfile { "fcgid_http.conf":
source => "puppet:///modules/apache/fcgid_http.conf",
https => false,
}
}
if defined(Class["apache::sslserver"]) {
file { "/var/run/mod_fcgid_httpsd":
ensure => directory,
mode => "0755",
owner => $apache::sslserver::user,
group => $apache::sslserver::group,
before => Service["httpsd"],
}
apache::configfile { "fcgid_https.conf":
source => "puppet:///modules/apache/fcgid_https.conf",
http => false,
}
} }
} }
default: { default: {
@ -748,15 +771,16 @@ class apache::mod::wsgi {
} }
} }
"centos","redhat","fedora": { "centos","redhat","fedora": {
apache::configfile { "wsgi.conf":
source => "puppet:///modules/apache/mod_wsgi.conf",
require => Package["mod_wsgi"],
}
file { "/var/run/mod_wsgi": file { "/var/run/mod_wsgi":
ensure => directory, ensure => directory,
mode => "0755", mode => "0755",
owner => "root", owner => "root",
group => "root", group => "root",
before => Apache::Configfile["wsgi.conf"],
}
apache::configfile { "wsgi.conf":
source => "puppet:///modules/apache/wsgi.conf",
require => Package["mod_wsgi"],
} }
} }
default: { default: {