RewriteEngine On
RewriteRule ^/$ /koji/  [R,L]

#We use wsgi by default
Alias /koji "/usr/share/koji-web/scripts/wsgi_publisher.py"
#(configuration goes in /etc/kojiweb/web.conf)

<Directory "/usr/share/koji-web/scripts/">
    Options ExecCGI
    SetHandler wsgi-script
    Order allow,deny
    Allow from all
</Directory>

<Location /koji/login>
    SSLVerifyClient require
    SSLVerifyDepth  10
    SSLOptions +StdEnvVars
</Location>


Alias /koji-static/ "/usr/share/koji-web/static/"

<Directory "/usr/share/koji-web/static/">
    Options None
    AllowOverride None
    Order allow,deny
    Allow from all
</Directory>

Alias /repos "/mnt/koji/repos/"

<Directory "/mnt/koji/repos/">
    Options Indexes FollowSymLinks
</Directory>

Alias /scratch "/mnt/koji/scratch/"

<Directory "/mnt/koji/scratch/">
    Options Indexes
</Directory>

Alias /work "/mnt/koji/work/"

<Directory "/mnt/koji/work/">
    Options Indexes FollowSymLinks
</Directory>

Alias /buildgroups "/mnt/koji/buildgroups/"

<Directory "/mnt/koji/buildgroups/">
    Options Indexes FollowSymLinks
</Directory>


RewriteRule ^/packages(.+) https://kojipkgs.fedoraproject.org/packages$1  [R=301,L]
