]> git.openstreetmap.org Git - chef.git/blob - cookbooks/gps-tile/templates/default/apache.erb
nominatim: custom log format
[chef.git] / cookbooks / gps-tile / templates / default / apache.erb
1 # DO NOT EDIT - This file is being maintained by Chef
2
3 <VirtualHost *:443>
4   # Basic server configuration
5   ServerName gps-tile.openstreetmap.org
6   ServerAlias *.gps-tile.openstreetmap.org
7   ServerAlias gps.tile.openstreetmap.org
8   ServerAlias gps-*.tile.openstreetmap.org
9   ServerAdmin webmaster@openstreetmap.org
10
11   # Enable SSL
12   SSLEngine on
13   SSLCertificateFile /etc/ssl/certs/gps-tile.openstreetmap.org.pem
14   SSLCertificateKeyFile /etc/ssl/private/gps-tile.openstreetmap.org.key
15
16   # Configure location of static files
17   DocumentRoot /srv/gps-tile.openstreetmap.org/html
18
19   # Configure the CGI script that serves the tiles
20   ScriptAlias /lines /srv/gps-tile.openstreetmap.org/updater/tile
21
22   # Temporary redirect for old CGI location
23   RedirectPermanent /gps-lines/tile /lines
24
25   # Setup logging
26   CustomLog /var/log/apache2/access.log combined_extended
27   ErrorLog /var/log/apache2/error.log
28
29   # Always set Access-Control-Allow-Origin so that simple CORS requests
30   # will always work and can be cached
31   Header set Access-Control-Allow-Origin "*"
32 </VirtualHost>
33
34 <VirtualHost *:80>
35   # Basic server configuration
36   ServerName gps-tile.openstreetmap.org
37   ServerAlias *.gps-tile.openstreetmap.org
38   ServerAlias gps.tile.openstreetmap.org
39   ServerAlias gps-*.tile.openstreetmap.org
40   ServerAdmin webmaster@openstreetmap.org
41
42   # Enable rewriting
43   RewriteEngine On
44
45   # Redirect for ACME challenge validation
46   RewriteRule ^/\.well-known/acme-challenge/(.*)$ http://acme.openstreetmap.org/.well-known/acme-challenge/$1 [R=permanent,L]
47
48   # Redirect to https
49   RewriteCond %{REQUEST_URI} !^/server-status
50   RewriteRule (.*) https://%{SERVER_NAME}/$1 [R=permanent,L]
51
52   # Setup logging
53   CustomLog /var/log/apache2/access.log combined_extended
54   ErrorLog /var/log/apache2/error.log
55 </VirtualHost>
56
57 <Directory /srv/gps-tile.openstreetmap.org/html>
58   Options None
59   AllowOverride None
60   Require all granted
61 </Directory>
62
63 <Directory /srv/gps-tile.openstreetmap.org/updater>
64   <Files tile>
65     Require all granted
66   </Files>
67 </Directory>