summaryrefslogtreecommitdiff
path: root/confs/apache
blob: 6184fb9269a315088dd9d52fd0146dab0942057a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
<VirtualHost *:80>
    DocumentRoot "/usr/local/shorten/htdocs"
 
    <Directory "/usr/local/shorten/htdocs">
        AllowOverride None
        Order allow,deny
        Allow from all
    </Directory>
 
    <Directory "/usr/local/shorten/cgi">
        AllowOverride None
        Order allow,deny
        Allow from all
        Options ExecCGI
    </Directory>
 
    RewriteEngine On
 
    RewriteCond %{ENV:SSL_PROXY} off
    RewriteRule ^/$ https://xn--yet.cc/ [R=301,L]
 
    RewriteCond %{ENV:SSL_PROXY} on
    RewriteRule ^/add$ /usr/local/shorten/cgi/shorten.pl/add [H=cgi-script,L]
 
    RewriteCond %{ENV:SSL_PROXY} on
    RewriteRule ^/$ /usr/local/shorten/htdocs/form.html [L]
 
    RewriteRule ^/(.*)$ /usr/local/shorten/cgi/shorten.pl/$1 [H=cgi-script,B,L]
 
 
    <IfModule peruser.c>
        # this must match a Processor
        ServerEnvironment apache apache
        
        # these are optional - defaults to the values specified in httpd.conf
        MinSpareProcessors 4
        MaxProcessors 20
    </IfModule>
 
</VirtualHost>