summaryrefslogtreecommitdiff
path: root/manifests/centos
diff options
context:
space:
mode:
authorMicah Anderson <micah@riseup.net>2013-04-12 13:23:29 -0400
committerMicah Anderson <micah@riseup.net>2013-04-12 14:37:28 -0400
commit115691c87bad3f5863f088e73603133b67c9f828 (patch)
treebbfd7b5c0d0c220ef3e52eb25acd4595a46b85d0 /manifests/centos
parent2401aae6c4785c1e6a777756bebe70c38b889727 (diff)
parent5ec141dfbf218dd9b2f2611d788db98f74e65073 (diff)
Merge remote-tracking branch 'immerda/master'
Fixed apache_no_default_site variable to be a parameter to the apache class (no_default_site = false) Conflicts: files/include.d/Debian/ssl_defaults.inc manifests/base.pp manifests/config/file.pp manifests/vhost.pp manifests/vhost/php/standard.pp manifests/vhost/template.pp templates/vhosts/php/CentOS.erb templates/vhosts/php/Debian.erb
Diffstat (limited to 'manifests/centos')
-rw-r--r--manifests/centos/itk.pp4
-rw-r--r--manifests/centos/itk_plus.pp20
-rw-r--r--manifests/centos/module.pp14
-rw-r--r--manifests/centos/worker.pp5
4 files changed, 33 insertions, 10 deletions
diff --git a/manifests/centos/itk.pp b/manifests/centos/itk.pp
index 94f0f1c..20f4270 100644
--- a/manifests/centos/itk.pp
+++ b/manifests/centos/itk.pp
@@ -5,8 +5,6 @@ class apache::centos::itk inherits apache::centos {
name => 'httpd-itk',
}
File['apache_service_config']{
- source => [ "puppet://$server/modules/site-apache/service/CentOS/${fqdn}/httpd.itk",
- "puppet://$server/modules/site-apache/service/CentOS/httpd.itk",
- "puppet://$server/modules/apache/service/CentOS/httpd.itk" ],
+ source => "puppet:///modules/apache/service/${::operatingsystem}/httpd.itk"
}
}
diff --git a/manifests/centos/itk_plus.pp b/manifests/centos/itk_plus.pp
new file mode 100644
index 0000000..0df92c8
--- /dev/null
+++ b/manifests/centos/itk_plus.pp
@@ -0,0 +1,20 @@
+# http://hostby.net/home/2008/07/12/centos-5-and-mpm-itk/
+class apache::centos::itk_plus inherits apache::centos::itk {
+ Exec['adjust_pidfile']{
+ command => "sed -i 's/^PidFile \\(.*\\)/#PidFile \\1/g' /etc/httpd/conf/httpd.conf",
+ unless => "grep -qE '^#PidFile ' /etc/httpd/conf/httpd.conf",
+ }
+ Exec['adjust_listen']{
+ command => "sed -i 's/^Listen 80/#Listen 80/g' /etc/httpd/conf/httpd.conf",
+ unless => "grep -qE '^#Listen 80' /etc/httpd/conf/httpd.conf",
+ }
+
+ Apache::Config::Global['00-listen.conf']{
+ ensure => 'present',
+ content => template("apache/itk_plus/${::operatingsystem}/00-listen.conf.erb"),
+ }
+
+ File['apache_service_config']{
+ source => "puppet:///modules/apache/service/CentOS/httpd.itk_plus"
+ }
+}
diff --git a/manifests/centos/module.pp b/manifests/centos/module.pp
index 4bbf251..3220d1f 100644
--- a/manifests/centos/module.pp
+++ b/manifests/centos/module.pp
@@ -3,20 +3,20 @@ define apache::centos::module(
$source = '',
$destination = ''
){
- $modules_dir = "$apache::centos::config_dir/modules.d"
+ $modules_dir = "${apache::centos::config_dir}/modules.d"
$real_destination = $destination ? {
'' => "${modules_dir}/${name}.so",
default => $destination,
}
$real_source = $source ? {
'' => [
- "puppet://$server/modules/site-apache/modules.d/${fqdn}/${name}.so",
- "puppet://$server/modules/site-apache/modules.d/${apache_cluster_node}/${name}.so",
- "puppet://$server/modules/site-apache/modules.d/${name}.so",
- "puppet://$server/modules/apache/modules.d/${operatingsystem}/${name}.so",
- "puppet://$server/modules/apache/modules.d/${name}.so"
+ "puppet:///modules/site_apache/modules.d/${::fqdn}/${name}.so",
+ "puppet:///modules/site_apache/modules.d/${apache::cluster_node}/${name}.so",
+ "puppet:///modules/site_apache/modules.d/${name}.so",
+ "puppet:///modules/apache/modules.d/${::operatingsystem}/${name}.so",
+ "puppet:///modules/apache/modules.d/${name}.so"
],
- default => "puppet://$server/$source",
+ default => "puppet:///$source",
}
file{"modules_${name}.conf":
ensure => $ensure,
diff --git a/manifests/centos/worker.pp b/manifests/centos/worker.pp
new file mode 100644
index 0000000..f374bb7
--- /dev/null
+++ b/manifests/centos/worker.pp
@@ -0,0 +1,5 @@
+class apache::centos::worker inherits apache::centos {
+ File['apache_service_config']{
+ source => "puppet:///modules/apache/service/${::operatingsystem}/httpd.worker"
+ }
+}