1 # DO NOT EDIT - This file is being maintained by Chef
3 WSGIDaemonProcess <%= @user %>.dev.openstreetmap.org user=<%= @user %> inactivity-timeout=600
6 ServerName <%= @user %>.dev.openstreetmap.org
7 ServerAdmin webmaster@openstreetmap.org
8 ServerAlias <%= @user %>.dev.osm.org
11 SSLCertificateFile /etc/ssl/certs/<%= @user %>.dev.openstreetmap.org.pem
12 SSLCertificateKeyFile /etc/ssl/private/<%= @user %>.dev.openstreetmap.org.key
14 # Remove Proxy request header to mitigate https://httpoxy.org/
15 RequestHeader unset Proxy early
18 DocumentRoot <%= @directory %>
19 ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
21 WSGIProcessGroup <%= @user %>.dev.openstreetmap.org
24 #LogLevel rewrite:trace2
26 CustomLog /var/log/apache2/<%= @user %>.dev.openstreetmap.org-access.log combined
27 ErrorLog /var/log/apache2/<%= @user %>.dev.openstreetmap.org-error.log
29 RewriteCond <%= @directory %>%{REQUEST_FILENAME} -f
30 RewriteRule ^/cgi-bin/(.*)$ /~<%= @user %>/cgi-bin/$1 [PT,L]
32 RewriteCond <%= @directory %>%{REQUEST_FILENAME} -f
33 RewriteRule ^/(.*\.ph(p|ps|p3|tml)(/.*)?)$ fcgi://127.0.0.1:<%= @port %><%= @directory %>/$1 [P]
37 ServerName <%= @user %>.dev.openstreetmap.org
38 ServerAdmin webmaster@openstreetmap.org
39 ServerAlias <%= @user %>.dev.osm.org
41 CustomLog /var/log/apache2/<%= @user %>.dev.openstreetmap.org-access.log combined
42 ErrorLog /var/log/apache2/<%= @user %>.dev.openstreetmap.org-error.log
44 RedirectPermanent /.well-known/acme-challenge/ http://acme.openstreetmap.org/.well-known/acme-challenge/
45 RedirectPermanent / https://<%= @user %>.dev.openstreetmap.org/
48 <Directory <%= @directory %>>
49 AllowOverride AuthConfig FileInfo Indexes Options=RailsBaseURI
50 Options SymLinksIfOwnerMatch Indexes Includes
54 <Directory <%= @directory %>/cgi-bin>
56 Options ExecCGI SymLinksIfOwnerMatch
60 <Directory <%= @directory %>/wsgi-bin>
61 SetHandler wsgi-script
62 Options ExecCGI SymLinksIfOwnerMatch