Move and conditionalize release.d.o vhost
[mirror/dsa-puppet.git] / modules / roles / templates / static-mirroring / vhost / static-vhosts-simple.erb
index 04691c5..d01dc63 100644 (file)
@@ -36,9 +36,9 @@ vhost(lines, "news.debian.net"         , "ssl")
 vhost(lines, "debaday.debian.net"      , "ssl")
 vhost(lines, "timeline.debian.net"     , "ssl")
 vhost(lines, "network-test.debian.org" , "with-extra", '"ServerAlias network-test-backend.debian.org"')
-vhost(lines, "blends.debian.org"       , "with-extra", '"ServerAlias blends-backend.debian.org"')
-vhost(lines, "wnpp-by-tags.debian.net" , "with-extra", '"ServerAlias wnpp-by-tags-backend.debian.org"')
-vhost(lines, "security-team.debian.org", "with-extra", '"ServerAlias security-team-backend.debian.org"')
+vhost(lines, "blends.debian.org"       , "ssl")
+vhost(lines, "wnpp-by-tags.debian.net" , "ssl")
+vhost(lines, "security-team.debian.org", "ssl")
 vhost(lines, "d-i.debian.org"      , "ssl")
 vhost(lines, "appstream.debian.org", "ssl")
 vhost(lines, "dsa.debian.org"      , "ssl")
@@ -116,6 +116,24 @@ lines.join("\n")
 </VirtualHost>
 <% end -%>
 
+######################
+# release.debian.org
+<% if scope.function_has_static_component(['release.debian.org']) -%>
+Use common-dsa-vhost-https-redirect release.debian.org
+<VirtualHost <%= vhost_listen_443 %> >
+       ServerName release.debian.org
+       ServerAdmin debian-admin@debian.org
+
+       ErrorLog /var/log/apache2/release.debian.org-error.log
+       CustomLog /var/log/apache2/release.debian.org-access.log privacy
+
+       Use common-debian-service-ssl release.debian.org
+       Use common-ssl-HSTS
+
+       Use common-static-base release.debian.org
+</VirtualHost>
+<% end -%>
+
 # www.backports.org
 ###################
 # www.backports.org is the historical place for the backports
@@ -142,7 +160,7 @@ Use common-dsa-vhost-https-redirect www.ports.debian.org
        ErrorLog /var/log/apache2/www.ports.debian.org-error.log
        CustomLog /var/log/apache2/www.ports.debian.org-access.log privacy
 
-       Use common-debian-service-ssl $name
+       Use common-debian-service-ssl www.ports.debian.org
        Use common-ssl-HSTS
 
        <IfModule mod_userdir.c>
@@ -167,14 +185,29 @@ Use common-dsa-vhost-https-redirect www.ports.debian.org
        ServerName www.debian-ports.org
        ServerAlias debian-ports.org
        ServerAdmin debian-admin@debian.org
-       RedirectPermanent / http://www.ports.debian.org/
+       RedirectPermanent / https://www.ports.debian.org/
 </VirtualHost>
 
 <VirtualHost <%= vhost_listen %> >
        ServerName ports.debian.org
        ServerAlias ports.debian.net
        ServerAdmin debian-admin@debian.org
-       RedirectPermanent / http://www.ports.debian.org/
+       RedirectPermanent / https://www.ports.debian.org/
+</VirtualHost>
+
+<VirtualHost <%= vhost_listen %> >
+       ServerName incoming.debian-ports.org
+       ServerAdmin debian-admin@debian.org
+       RedirectPermanent / http://incoming.ports.debian.org/
+</VirtualHost>
+
+<VirtualHost <%= vhost_listen %> >
+       ServerName ftp.debian-ports.org
+       ServerAdmin debian-admin@debian.org
+       RedirectPermanent /archive http://www.ports.debian.org
+       RedirectPermanent /debian http://ftp.ports.debian.org/debian-ports
+       RedirectPermanent /debian-cd http://ftp.ports.debian.org/debian-ports-cd
+       RedirectPermanent / http://ftp.ports.debian.org/
 </VirtualHost>
 
 # video.debian.net