X-Git-Url: https://git.adam-barratt.org.uk/?a=blobdiff_plain;ds=inline;f=modules%2Froles%2Ftemplates%2Fstatic-mirroring%2Fvhost%2Fstatic-vhosts-simple.erb;h=e10c2f1bb9d8da647d87446bdb1b0245afc2c244;hb=5463c4ab3827514ab3fbcdab8ed88b89c319ec59;hp=d01dc636765d0458d2089015e5b65c4cde09a0c4;hpb=f2b38e8aba64eea463246187ee44ec71bb0d204d;p=mirror%2Fdsa-puppet.git
diff --git a/modules/roles/templates/static-mirroring/vhost/static-vhosts-simple.erb b/modules/roles/templates/static-mirroring/vhost/static-vhosts-simple.erb
index d01dc6367..e10c2f1bb 100644
--- a/modules/roles/templates/static-mirroring/vhost/static-vhosts-simple.erb
+++ b/modules/roles/templates/static-mirroring/vhost/static-vhosts-simple.erb
@@ -11,18 +11,34 @@
<% end -%>
+
+ ServerAlias network-test-backend.debian.org
+
+
+
+
+ CustomLog /var/log/apache2/bits.debian.org-public-access.log privacy+geo
+
+
+
+
+ AddDefaultCharset utf-8
+
+ ForceType text/plain
+
+
<%=
-def vhost(lines, sn, type=nil, extra=nil)
+def vhost(lines, sn, type=nil)
if scope.function_has_static_component([sn])
t = 'common-static-vhost'
if type then t += "-#{type}"; end
- e = ''
- if extra then e += " #{extra}"; end
+ onion = scope.function_onion_global_service_hostname([sn])
+ onion = "unavailable-onion.invalid" if onion.nil?
- lines << "Use #{t} #{sn}#{e}"
+ lines << "Use #{t} #{sn} #{onion}"
end
end
@@ -35,7 +51,7 @@ vhost(lines, "debdeltas.debian.net")
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, "network-test.debian.org" , "with-extra")
vhost(lines, "blends.debian.org" , "ssl")
vhost(lines, "wnpp-by-tags.debian.net" , "ssl")
vhost(lines, "security-team.debian.org", "ssl")
@@ -44,6 +60,9 @@ vhost(lines, "appstream.debian.org", "ssl")
vhost(lines, "dsa.debian.org" , "ssl")
vhost(lines, "rtc.debian.org" , "ssl")
+vhost(lines, "bits.debian.org", "ssl-with-extra")
+vhost(lines, "metadata.ftp-master.debian.org", "with-extra")
+
vhost(lines, "10years.debconf.org" , "ssl")
vhost(lines, "debconf0.debconf.org", "ssl")
vhost(lines, "debconf1.debconf.org", "ssl")
@@ -57,65 +76,11 @@ vhost(lines, "es.debconf.org" , "ssl")
vhost(lines, "fr.debconf.org" , "ssl")
vhost(lines, "miniconf10.debconf.org" , "ssl")
-vhost(lines, "deb.debian.org", "with-extra", '"Use vhost-deb.debian.org-extra"')
+vhost(lines, "deb.debian.org", "with-extra")
lines.join("\n")
-%>
-######################
-# metadata.ftp-master.debian.org
-<% if scope.function_has_static_component(['metadata.ftp-master.debian.org']) -%>
- >
- ServerName metadata.ftp-master.debian.org
- ServerAdmin debian-admin@lists.debian.org
-
- ErrorLog /var/log/apache2/metadata.ftp-master.debian.org-error.log
- CustomLog /var/log/apache2/metadata.ftp-master.debian.org-access.log privacy
-
- Use common-static-base metadata.ftp-master.debian.org
- AddDefaultCharset utf-8
-
- ForceType text/plain
-
-
-<% end -%>
-
-######################
-# bits.debian.org
-<% if scope.function_has_static_component(['bits.debian.org']) -%>
-
- ServerName bits.debian.org
- ServerAdmin debian-admin@lists.debian.org
-
- ErrorLog /var/log/apache2/bits.debian.org-error.log
-
- CustomLog /var/log/apache2/bits.debian.org-public-access.log privacy+geo
-
-
- Use common-static-base bits.debian.org
-
-
- >
- RewriteEngine on
-
- RewriteEngine On
- RewriteCond %{REQUEST_URI} !^/feeds/
- RewriteRule ^/(.*)$ https://bits.debian.org/$1 [R,L]
- #RewriteRule ^/(.*)$ https://bits.debian.org/$1 [R=301,L]
-
- Use static-bits.debian.org-base
- CustomLog /var/log/apache2/bits.debian.org-access.log privacy
-
-
- >
- Use static-bits.debian.org-base
- CustomLog /var/log/apache2/bits.debian.org-access.log privacyssl
-
- Use common-debian-service-ssl bits.debian.org
- Use common-ssl-HSTS
-
-<% end -%>
-
######################
# release.debian.org
<% if scope.function_has_static_component(['release.debian.org']) -%>
@@ -131,6 +96,28 @@ Use common-dsa-vhost-https-redirect release.debian.org
Use common-ssl-HSTS
Use common-static-base release.debian.org
+
+ RewriteEngine on
+ RewriteRule ^/migration/$ /migration/testing.pl
+ RewriteRule ^/migration/search/(.+)/$ /migration/testing.pl?package=$1
+ RewriteCond %{QUERY_STRING} package=((.)(.*))
+ RewriteRule ^/migration/testing.pl /migration/cache/%2/%1.html [PT,L]
+ RewriteRule ^/migration/testing.pl /migration/cache/_index.html
+
+ Alias /proposed-updates/ /srv/static.debian.org/mirrors/release.debian.org-pu/cur/
+
+ Require all granted
+ Options Indexes SymLinksIfOwnerMatch MultiViews
+ IndexOptions FancyIndexing NameWidth=*
+
+ AddEncoding gzip .gz
+ FilterDeclare gzip CONTENT_SET
+ FilterProvider gzip inflate "%{req:Accept-Encoding} !~ /gzip/"
+ FilterChain gzip
+
+ ForceType text/plain
+
+
<% end -%>
@@ -152,16 +139,12 @@ Use common-dsa-vhost-https-redirect release.debian.org
Use common-dsa-vhost-https-redirect www.ports.debian.org
- >
- ServerName www.ports.debian.org
- ServerAlias www.ports-backend.debian.org
+
ServerAdmin debian-admin@lists.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 www.ports.debian.org
- Use common-ssl-HSTS
UserDir disabled
@@ -178,8 +161,22 @@ Use common-dsa-vhost-https-redirect www.ports.debian.org
AddOutputFilterByType DEFLATE text/html text/plain text/xml text/css
AddOutputFilter INCLUDES .xhtml
+
+
+ >
+ ServerName www.ports.debian.org
+ ServerAlias www.ports-backend.debian.org
+ Use common-debian-service-ssl www.ports.debian.org
+ Use common-ssl-HSTS
+ Use vhost-inner-www.ports.debian.org
+
+<% if scope.function_onion_global_service_hostname(['www.ports.debian.org']) -%>
+ >
+ ServerName <%= scope.function_onion_global_service_hostname(['www.ports.debian.org']) %>
+ Use vhost-inner-www.ports.debian.org
<% end -%>
+<% end -%>
>
ServerName www.debian-ports.org