1. /etc/apache2/sites-available/default
<VirtualHost *:80>
ServerAdmin webmaster@localhost
DocumentRoot /var/www
<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>
<Directory /var/www/>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
</Directory>
ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
<Directory "/usr/lib/cgi-bin">
AllowOverride None
Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
Order allow,deny
Allow from all
</Directory>
ErrorLog /var/log/apache2/error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
CustomLog /var/log/apache2/access.log combined
Alias /doc/ "/usr/share/doc/"
<Directory "/usr/share/doc/">
Options Indexes MultiViews FollowSymLinks
AllowOverride None
Order deny,allow
Deny from all
Allow from 127.0.0.0/255.0.0.0 ::1/128
</Directory>
</VirtualHost>
2. apache.conf
Bedoel je dit (?): /etc/apache2/apache2.conf
Dat is een ´lap´ platte tekst bij mij.
3. .htaccess files
/var/www/test_site/admin/.htaccess:
AuthGroupFile /dev/null
AuthType Basic
AuthUserFile /home/coenr/domains/mijndomein.nl/.htpasswd/public_html/admin/.htpasswd
AuthName "adminonly"
require valid-user
/var/www/test_site/catalog/.htaccess:
Options +FollowSymlinks
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !^(.+)\.jpg$
RewriteCond %{REQUEST_FILENAME} !^(.+)\.jpeg$
RewriteCond %{REQUEST_FILENAME} !^(.+)\.png$
RewriteCond %{REQUEST_FILENAME} !^(.+)\.gif$
RewriteCond %{REQUEST_FILENAME} !^(.+)\.css$
RewriteCond %{REQUEST_FILENAME} !^(.+)\.js$
RewriteRule ^(.+)$ /noaccess/ [NC]
Admin + homepage werken goed. Catalog niet!
Deze zijn er ook nog:
/var/www/test_site/cgi-bin/.htaccess
/var/www/test_site/download/.htaccess
/var/www/test_site/image/.htaccess
/var/www/test_site/noaccess/.htaccess
/var/www/test_site/system/.htaccess
/var/www/test_site/vqmod/.htaccess