aboutsummaryrefslogtreecommitdiffstats
path: root/modules/apache/manifests/base.pp
diff options
context:
space:
mode:
Diffstat (limited to 'modules/apache/manifests/base.pp')
-rw-r--r--modules/apache/manifests/base.pp35
1 files changed, 35 insertions, 0 deletions
diff --git a/modules/apache/manifests/base.pp b/modules/apache/manifests/base.pp
new file mode 100644
index 00000000..e94c596b
--- /dev/null
+++ b/modules/apache/manifests/base.pp
@@ -0,0 +1,35 @@
+class apache::base {
+
+ # number of time the log file are rotated before being removed
+ $httpdlogs_rotate = '24'
+
+ $apache_user = 'apache'
+ $apache_group = 'apache'
+
+ package { 'apache-mpm-prefork':
+ alias => 'apache',
+ }
+
+ package { 'apache-conf': }
+
+ service { 'httpd':
+ alias => 'apache',
+ subscribe => [ Package['apache-mpm-prefork'] ],
+ }
+
+ exec { 'service httpd configtest':
+ refreshonly => true,
+ notify => Service['apache'],
+ }
+
+ apache::config {
+ '/etc/httpd/conf.d/customization.conf':
+ content => template('apache/customization.conf');
+ '/etc/httpd/conf/vhosts.d/00_default_vhosts.conf':
+ content => template('apache/00_default_vhosts.conf');
+ }
+
+ file { '/etc/logrotate.d/httpd':
+ content => template('apache/logrotate')
+ }
+}