aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-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