lemonldap-ng/build/lemonldap-ng/_example/etc/apache2.conf

125 lines
2.7 KiB
ApacheConf

NameVirtualHost *
# Perl environment
PerlRequire __HANDLER__
PerlOptions +GlobalRequest
<Files ~ "\.(pl)$">
SetHandler perl-script
PerlHandler ModPerl::Registry
PerlSendHeader On
</Files>
<IfModule mod_dir.c>
DirectoryIndex index.pl index.html
</IfModule>
# Common error page and security parameters
ErrorDocument 403 http://auth.__DNSDOMAIN__/error.pl
ServerSignature Off
LogLevel warn
# Portal virtual host
<VirtualHost *>
ServerName auth.__DNSDOMAIN__
# DocumentRoot
DocumentRoot __PORTALDIR__
<Directory __PORTALDIR__>
Order allow,deny
Allow from all
Options +ExecCGI
</Directory>
</VirtualHost>
# Manager virtual host
<VirtualHost *>
ServerName manager.__DNSDOMAIN__
# DocumentRoot
DocumentRoot __MANAGERDIR__
<Directory __MANAGERDIR__>
Order deny,allow
Deny from all
Allow from 127.0.0.0/8
Options +ExecCGI
</Directory>
# On-line documentation
Alias /docs/ __DOCDIR__/docs/
<Directory __DOCDIR__/docs/>
Order deny,allow
Allow from all
</Directory>
</VirtualHost>
# Application Test
<VirtualHost *>
ServerName test1.__DNSDOMAIN__
# SSO protection
PerlHeaderParserHandler My::Package
# DocumentRoot
DocumentRoot __TESTDIR__
<Directory __TESTDIR__>
Order deny,allow
Allow from all
Options +ExecCGI
</Directory>
# Configuration reload mechanism (only 1 per physical server is
# needed): choose your URL to avoid restarting Apache when
# configuration change
<Location /reload>
Order deny,allow
Deny from all
Allow from 127.0.0.0/8
PerlHeaderParserHandler My::Package->refresh
</Location>
# Uncomment this to activate status module
#<Location /status>
# Order deny,allow
# Deny from all
# Allow from 127.0.0.0/8
# PerlHeaderParserHandler My::Package->status
#</Location>
</VirtualHost>
<VirtualHost *>
ServerName test2.__DNSDOMAIN__
# SSO protection
PerlHeaderParserHandler My::Package
# DocumentRoot
DocumentRoot __TESTDIR__
<Directory __TESTDIR__>
Order deny,allow
Allow from all
Options +ExecCGI
</Directory>
# Configuration reload mechanism (only 1 per physical server is
# needed): choose your URL to avoid restarting Apache when
# configuration change
<Location /reload>
Order deny,allow
Deny from all
Allow from 127.0.0.0/8
PerlHeaderParserHandler My::Package->refresh
</Location>
# Uncomment this to activate status module
#<Location /status>
# Order deny,allow
# Deny from all
# Allow from 127.0.0.0/8
# PerlHeaderParserHandler My::Package->status
#</Location>
</VirtualHost>