lemonldap-ng/_example/etc/manager-apache2.4.conf

77 lines
2.4 KiB
Plaintext
Raw Normal View History

#====================================================================
# Apache configuration for LemonLDAP::NG Manager
#====================================================================
# Uncomment this if no previous NameVirtualHost declaration
#NameVirtualHost __VHOSTLISTEN__
# Manager virtual host (manager.__DNSDOMAIN__)
<VirtualHost __VHOSTLISTEN__>
ServerName manager.__DNSDOMAIN__
# DocumentRoot
DocumentRoot __MANAGERDIR__
2015-06-10 22:40:23 +02:00
<Directory __MANAGERSTATICDIR__>
2014-03-05 13:21:41 +01:00
Require all granted
2015-06-10 22:40:23 +02:00
Options +FollowSymLinks
</Directory>
# On-line documentation
2014-04-18 12:17:08 +02:00
Alias /doc/ __DEFDOCDIR__
Alias /lib/ __DEFDOCDIR__lib/
<Directory __DEFDOCDIR__>
2014-03-05 13:21:41 +01:00
Require all granted
ErrorDocument 404 /notfound.html
Options +FollowSymLinks
</Directory>
2014-04-18 12:17:08 +02:00
# French version (needs fr-doc installation)
Alias /fr-doc/ __FRDOCDIR__
<Directory __FRDOCDIR__>
Require all granted
ErrorDocument 404 /notfoundfr.html
Options +FollowSymLinks
</Directory>
# Perl script
2015-06-10 22:40:23 +02:00
# Note: to increase performance, you can avoid manager stay in memory
# by using "SetHandler cgi-script" instead of Plack framework
2015-06-11 07:35:41 +02:00
RewriteEngine on
RewriteRule ^/$ /index.pl [R]
<Location /index.pl>
Require all granted
2015-06-10 22:40:23 +02:00
#SetHandler cgi-script
Options +ExecCGI
SetHandler perl-script
PerlResponseHandler Plack::Handler::Apache2
PerlSetVar psgi_app __MANAGERPSGIDIR__/manager-server.psgi
2015-06-11 07:35:41 +02:00
</Location>
<Location />
<IfModule mod_deflate.c>
2014-03-05 13:21:41 +01:00
AddOutputFilterByType DEFLATE text/html text/plain text/xml text/javascript text/css
SetOutputFilter DEFLATE
BrowserMatch ^Mozilla/4 gzip-only-text/html
BrowserMatch ^Mozilla/4\.0[678] no-gzip
BrowserMatch \bMSIE !no-gzip !gzip-only-text/html
SetEnvIfNoCase Request_URI \.(?:gif|jpe?g|png)$ no-gzip dont-vary
</IfModule>
<IfModule mod_headers.c>
2014-03-05 13:21:41 +01:00
Header append Vary User-Agent env=!dont-vary
</IfModule>
</Location>
<Location /doc/>
2014-03-05 13:21:41 +01:00
<IfModule mod_expires.c>
ExpiresActive On
ExpiresDefault "access plus 1 month"
</IfModule>
</Location>
2015-06-10 22:40:23 +02:00
<Location /static/>
2014-03-05 13:21:41 +01:00
<IfModule mod_expires.c>
ExpiresActive On
ExpiresDefault "access plus 1 month"
</IfModule>
</Location>
</VirtualHost>