summaryrefslogtreecommitdiff
path: root/manifests
diff options
context:
space:
mode:
Diffstat (limited to 'manifests')
-rw-r--r--manifests/init.pp8
1 files changed, 7 insertions, 1 deletions
diff --git a/manifests/init.pp b/manifests/init.pp
index 73852f1..3c6bcb5 100644
--- a/manifests/init.pp
+++ b/manifests/init.pp
@@ -42,6 +42,7 @@ class apache {
}
service { "apache":
+ name => "apache2",
ensure => running,
require => Package["apache"],
hasstatus => true,
@@ -73,7 +74,6 @@ class apache {
'': { $apache_www_folder = '/var/www' }
}
- # TODO: ensure folders exist with right modes and ownership
define site($ensure = present, $docroot = false, $redirect = false,
$protocol = 'http', $server_alias = false, $use = false) {
file { "${apache2_sites}-available/$title":
@@ -107,6 +107,12 @@ class apache {
&& [ ${apache2_sites}-enabled/$name -ef ${apache2_sites}-available/$name ]'",
notify => Exec["reload-apache2"],
}
+ file { "${docroot}":
+ ensure => directory,
+ owner => root,
+ group => root,
+ mode => 0755,
+ }
}
'absent': {
exec { "/usr/sbin/a2dissite $name":