# pirates.conf - config file for Pirates@Home web server
#
# Generated by make_project on 02Jun2004 by kilefkowitz
# Modified to run at Spy Hill on 15Dec2005 by myers
#
# This file is included by conf/httpd.conf
#
#  * Added Alias and permission for /download area -EAM 08Sep2004
#  * Added Alias for /help                         -EAM 09Oct2004
#  * Enabled Option IncludesNoExec and x-bit hack  -EAM 09Sep2004
#  * Added /wiki for mediawiki testing	           -EAM 01Apr2006
#  * Added /doc for BOINC on-line documentation    -EAM 22May2006
#  * Changed /wiki to /glossary			   -EAM 19Jun2006
#
#  @(#) Last changed: -EAM 29Aug2006
######################################################################


<VirtualHost 192.168.1.12:80 >
   ServerName pirates.spy-hill.net
   ServerAdmin myers@spy-hill.net
   DocumentRoot "/usr02/pirates/html/user"
   UserDir disabled

   CustomLog    /usr02/pirates/log_alvarez/httpd_access.log combined
   ErrorLog     /usr02/pirates/log_alvarez/httpd_error.log

   ScriptAlias  /cgi-bin /usr02/pirates/cgi-bin

   AliasMatch ^/languages/project_specific_translations(.*)   /usr02/pirates/html/languages/project_specific_translations$1
   Alias       /languages/translator.log		      /usr02/pirates/html/languages/translator.log

   Alias      /ops             /usr02/pirates/html/ops
   Alias      /download        /usr02/pirates/download
   Alias      /stats           /usr02/pirates/html/stats
   Alias      /user_profile    /usr02/pirates/html/user_profile
   Alias      /doc	       /usr02/pirates/html/doc
   Alias      /help            /net/moonflower/home/myers/www/help/boinc

   Alias      /glossary	       /usr02/pirates/html/glossary
   Redirect   /wiki	       http://pirates.spy-hill.net/glossary

   AliasMatch ^/pub(.*)        /net/moonflower/home2/ftp/pub$1

   AddIcon /icons/xml.png .xml

   # Note: projects/*/keys/ should NOT be readable!

   # BOINC is a world-wide project, so times in GMT:
   setEnv TZ GMT

   # Necessary for cgi programs to find GCC-3.3 libraries in /usr/local/lib
   SetEnv LD_LIBRARY_PATH /usr/local/lib:/usr/lib

   #############
   # Directories and their permissions & options

   # Main user pages:

   <Directory "/usr02/pirates/html/user">
        Options Indexes FollowSymlinks MultiViews IncludesNoExec
        AllowOverride AuthConfig Limit Indexes
        Order allow,deny
        Allow from all
        <IfModule mod_include.c>
           XBitHack Full
        </IfModule>
    </Directory>

    # Scheduler and file upload handler:

    <Directory "/usr02/pirates/cgi-bin">
        Options ExecCGI
        AllowOverride AuthConfig Limit
        Order allow,deny
        Allow from all
    </Directory>

    # download area

    <Directory "/usr02/pirates/download">
        Options Indexes FollowSymlinks MultiViews
        AllowOverride AuthConfig Limit Indexes
        Order allow,deny
        Allow from all
    </Directory>

    # User profiles

    <Directory "/usr02/pirates/html/user_profile">
        Options IncludesNoExec
        AllowOverride AuthConfig Limit Indexes
        Order allow,deny
        Allow from all
        <IfModule mod_include.c>
           XBitHack Full
        </IfModule>
    </Directory>

    # upload area is not directly accessible to the web.  The 
    # file_upload_handler in cgi-bin puts things here
    
    <Directory "/usr02/pirates/upload">
        Order deny,allow
        Deny  from all
    </Directory>

    # Operations area (should be protected via .htaccess) 

    <Directory "/usr02/pirates/html/ops">
        Options Indexes FollowSymlinks MultiViews IncludesNoExec
        AllowOverride FileInfo AuthConfig Limit Indexes 
        <IfModule mod_include.c>
           XBitHack Full
        </IfModule>
    </Directory>

    # Statistics records for team and stats sites

    <Directory "/usr02/pirates/html/stats">
        Options Indexes MultiViews
        AllowOverride AuthConfig Limit Indexes
        Order allow,deny
        Allow from all
    </Directory>

    # Developers Help files are linked to this directory:

    <Directory "/home/myers/www/help/boinc">
        Options Indexes SymLinksIfOwnerMatch IncludesNoExec
        AllowOverride FileInfo AuthConfig Limit Indexes 
        IndexOptions FancyIndexing FoldersFirst IconsAreLinks ScanHTMLTitles 

        Order allow,deny
        Allow from all

        <IfModule mod_include.c>
           XBitHack Full
        </IfModule>
    </Directory>

</VirtualHost>


##############################
# Redirect pirates.spy-hill.com to .net

<VirtualHost 192.168.1.12:80 >
   ServerName pirates.spy-hill.com
   ServerAdmin myers@spy-hill.com

   Redirect permanent  /  http://pirates.spy-hill.net

</VirtualHost>

##
