aboutsummaryrefslogtreecommitdiffstats
path: root/modules/mga-mirrors
diff options
context:
space:
mode:
authorMichael Scherer <misc@mageia.org>2010-11-05 01:04:35 +0000
committerMichael Scherer <misc@mageia.org>2010-11-05 01:04:35 +0000
commit4298cfdb25c5c67316c064724403c0aec76f7806 (patch)
tree0ef658e1ea3717eff40509fe2d81edb41854a583 /modules/mga-mirrors
parentf6c39c6f7b324825e5704d4b9f897cec39d047be (diff)
downloadpuppet-4298cfdb25c5c67316c064724403c0aec76f7806.tar
puppet-4298cfdb25c5c67316c064724403c0aec76f7806.tar.gz
puppet-4298cfdb25c5c67316c064724403c0aec76f7806.tar.bz2
puppet-4298cfdb25c5c67316c064724403c0aec76f7806.tar.xz
puppet-4298cfdb25c5c67316c064724403c0aec76f7806.zip
- refactor the vhost setting, and clean it
Diffstat (limited to 'modules/mga-mirrors')
-rw-r--r--modules/mga-mirrors/manifests/init.pp6
-rw-r--r--modules/mga-mirrors/templates/mirrors_vhost.conf3
2 files changed, 5 insertions, 4 deletions
diff --git a/modules/mga-mirrors/manifests/init.pp b/modules/mga-mirrors/manifests/init.pp
index 0da8832d..96a4fa7e 100644
--- a/modules/mga-mirrors/manifests/init.pp
+++ b/modules/mga-mirrors/manifests/init.pp
@@ -1,4 +1,6 @@
class mga-mirrors {
+
+ $vhost = "mirrors.$domain"
include apache::mod_fcgid
@@ -7,8 +9,8 @@ class mga-mirrors {
}
# add a apache vhost
- file { "mirrors.$domain.conf":
- path => "/etc/httpd/conf/vhosts.d/$name.$domain.conf",
+ file { "$vhost.conf":
+ path => "/etc/httpd/conf/vhosts.d/$vhost.conf",
ensure => "present",
owner => root,
group => root,
diff --git a/modules/mga-mirrors/templates/mirrors_vhost.conf b/modules/mga-mirrors/templates/mirrors_vhost.conf
index 21e4aa0c..33f27513 100644
--- a/modules/mga-mirrors/templates/mirrors_vhost.conf
+++ b/modules/mga-mirrors/templates/mirrors_vhost.conf
@@ -1,6 +1,5 @@
-NameVirtualHost *:80
<VirtualHost *:80>
- ServerName mirrors.<%= domain %>
+ ServerName <%= vhost %>
# Serve static content directly
DocumentRoot /dev/null