add back our git reversion
[mirror/dsa-puppet.git] / modules / roles / templates / static-mirroring / vhost / planet.debian.org.erb
1 <% if scope.function_has_static_component(['planet.debian.org']) -%>
2
3 <Virtualhost <%= vhost_listen %> >
4         ServerName planet.debian.org
5         ServerAlias planet.debian.net planeta.debian.net planet-backend.debian.org planet-fastly.debian.org planet-maxcdn.debian.org
6         <% if scope.function_onion_global_service_hostname(['planet.debian.org']) -%>
7         ServerAlias <%= scope.function_onion_global_service_hostname(['planet.debian.org']) %>
8         <% end %>
9         ServerAdmin planet@debian.org
10
11         ErrorLog /var/log/apache2/planet.debian.org-error.log
12         CustomLog /var/log/apache2/planet.debian.org-access.log privacy
13
14         <IfModule mod_userdir.c>
15                 UserDir disabled
16         </IfModule>
17
18         DocumentRoot /srv/static.debian.org/mirrors/planet.debian.org/cur
19         AddDefaultCharset utf-8
20         <Directory /srv/static.debian.org/mirrors/planet.debian.org/cur>
21                 Require all granted
22         </Directory>
23
24         RewriteEngine On
25         RewriteCond %{HTTP_HOST} ^planeta.debian.net$ [NC]
26         RewriteRule ^/(.*)        http://planet.debian.org/es/$1  [R=permanent,L]
27         RewriteCond %{HTTP_HOST} ^planet.debian.net$ [NC]
28         RewriteRule ^/(.*)        http://planet.debian.org/$1  [R=permanent,L]
29 </VirtualHost>
30 <% end -%>
31
32 # vim:set syn=apache: