]> git.donarmstrong.com Git - dsa-puppet.git/commitdiff
Try this instead
authorPeter Palfrader <peter@palfrader.org>
Sun, 9 Dec 2012 11:55:11 +0000 (12:55 +0100)
committerPeter Palfrader <peter@palfrader.org>
Sun, 9 Dec 2012 11:55:11 +0000 (12:55 +0100)
modules/roles/files/static-mirroring/vhost/planet.debian.org
modules/roles/manifests/static_mirror.pp
modules/roles/templates/static-mirroring/apache-conf-static-mirror-macros.erb [deleted file]
modules/roles/templates/static-mirroring/apache-inc-static-mirror-vhost.erb [new file with mode: 0644]

index 22bf348b56984a9ab49a7c25504daac51c627a3f..8bda41fb16cd2fda4de81a88a5c13ce6b6c9877f 100644 (file)
@@ -1,4 +1,4 @@
-Use DebianStaticMirrorVhostLine
+Include /etc/apache2/inc/static-mirror-vhost
        ServerName planet.debian.org
        ServerAlias planet.debian.net planeta.debian.net
        ServerAdmin planet@debian.org
index 390e56338ca06e0271890c15cdb3c2a175ea6e00..8ba0fe91c0a408e07c5d9990a8c367ed8b1ded3d 100644 (file)
@@ -25,10 +25,12 @@ class roles::static_mirror inherits roles::static_source {
             content => "PATH=/usr/local/bin:/usr/bin:/bin\n@reboot staticsync sleep 60; static-mirror-run --one-stage /srv/static.debian.org bizet.debian.org:-live- > /dev/null\n",
             ;
 
-    }
-
-    apache2::config { 'static-mirror-macros':
-        content => template('roles/static-mirroring/apache-conf-static-mirror-macros.erb'),
+        '/etc/apache2/inc':
+            ensure => directory,
+            ;
+        '/etc/apache2/inc/static-mirror-vhost':
+            content => template('roles/static-mirroring/apache-inc-static-mirror-vhost.erb'),
+            ;
     }
 
     apache2::site { '010-planet.debian.org':
diff --git a/modules/roles/templates/static-mirroring/apache-conf-static-mirror-macros.erb b/modules/roles/templates/static-mirroring/apache-conf-static-mirror-macros.erb
deleted file mode 100644 (file)
index 20d2d97..0000000
+++ /dev/null
@@ -1,11 +0,0 @@
-##
-## THIS FILE IS UNDER PUPPET CONTROL. DON'T EDIT IT HERE.
-##
-
-<Macro DebianStaticMirrorVhostLine>
-<% if hostname == "klecker" -%>
-  <VirtualHost 130.89.148.14:80 2001:610:1908:b000::148:14:80>
-<% else -%>
-  <VirtualHost *:80>
-<% end -%>
-</Macro>
diff --git a/modules/roles/templates/static-mirroring/apache-inc-static-mirror-vhost.erb b/modules/roles/templates/static-mirroring/apache-inc-static-mirror-vhost.erb
new file mode 100644 (file)
index 0000000..20d2d97
--- /dev/null
@@ -0,0 +1,11 @@
+##
+## THIS FILE IS UNDER PUPPET CONTROL. DON'T EDIT IT HERE.
+##
+
+<Macro DebianStaticMirrorVhostLine>
+<% if hostname == "klecker" -%>
+  <VirtualHost 130.89.148.14:80 2001:610:1908:b000::148:14:80>
+<% else -%>
+  <VirtualHost *:80>
+<% end -%>
+</Macro>