#intranet ServerName {{ koha_intranet_hostname }} RedirectMatch permanent / https://{{ koha_intranet_hostname }} ServerAdmin webmaster@sciencespo-lyon.lan DocumentRoot {{ koha_install_dir }}/intranet/htdocs ServerName {{ koha_intranet_hostname }} ScriptAlias /cgi-bin/koha/ "{{ koha_install_dir }}/intranet/cgi-bin/" ScriptAlias /index.html "{{ koha_install_dir }}/intranet/cgi-bin/mainpage.pl" ScriptAlias /search "{{ koha_install_dir }}/intranet/cgi-bin/catalogue/search.pl" Alias /plugin/ "{{ koha_install_dir }}/var/lib/koha/plugins/" ErrorLog {{ koha_install_dir }}/var/log/koha-error_log TransferLog {{ koha_install_dir }}/var/log/koha-access.log SetEnv KOHA_CONF "{{ koha_install_dir }}/etc/koha-conf.xml" SetEnv PERL5LIB "{{ koha_install_dir }}/lib" SetEnv MEMCACHED_SERVERS "127.0.0.1:11211" SetEnv MEMCACHED_NAMESPACE "KOHA" SetEnv DEBUG 1 Options +FollowSymLinks SSLEngine on SSLProtocol all -SSLv2 SSLCipherSuite ALL:!ADH:!EXPORT:!SSLv2:RC4+RSA:+HIGH:+MEDIUM:+LOW SSLCertificateFile {{ koha_apache_ssl_cert }} SSLCertificateKeyFile {{ koha_apache_ssl_key }} SSLCertificateChainFile {{ koha_apache_ssl_chain }} ErrorDocument 400 /cgi-bin/koha/errors/400.pl ErrorDocument 401 /cgi-bin/koha/errors/401.pl ErrorDocument 403 /cgi-bin/koha/errors/403.pl ErrorDocument 404 /cgi-bin/koha/errors/404.pl ErrorDocument 500 /cgi-bin/koha/errors/500.pl require all granted Include /etc/koha/apache-shared-api-acl.conf Include /etc/koha/apache-shared-intranet-plack.conf Options -Indexes # Secure internal stuff # Compress content with type html, text, and css, ... AddOutputFilterByType DEFLATE text/plain text/html text/xml text/css AddOutputFilterByType DEFLATE application/xml application/xhtml+xml application/rss+xml application/javascript application/x-javascript DeflateCompressionLevel 9 # Properly handle old browsers that do not support compression BrowserMatch ^Mozilla/4 gzip-only-text/html BrowserMatch ^Mozilla/4\.0[678] no-gzip BrowserMatch \bMSIE !no-gzip !gzip-only-text/html DeflateFilterNote Input instream DeflateFilterNote Output outstream DeflateFilterNote Ratio ratio LogFormat '"%r" %{outstream}n/%{instream}n (%{ratio}n%%)' deflate #properly handle requests coming from behind proxies Header append Vary User-Agent # Rewrite Rules RewriteEngine On # Uncomment to turn on rewrite logging #RewriteLog {{ koha_install_dir }}/var/log/koha-intranet-rewrite.log #RewriteLogLevel 1 #The following two directives are unnecessary to proper Koha functioning. #RewriteCond %{QUERY_STRING} (.*?)(?:[A-Za-z0-9_-]+)=&(.*) #RewriteRule (.+) $1?%1%2 [N,R,NE] RewriteRule ^/bib/([^\/]*)/?$ /cgi-bin/koha/detail\.pl?bib=$1 [PT] RewriteRule ^/isbn/([^\/]*)/?$ /search?q=isbn:$1 [PT] RewriteRule ^/issn/([^\/]*)/?$ /search?q=issn:$1 [PT] RewriteRule ^(.*)_[0-9]{2}\.[0-9]{7}\.(js|css)$ $1.$2 [L] # REST API configuration Alias "/api" "{{ koha_install_dir }}/api" Options +ExecCGI +FollowSymlinks AddHandler cgi-script .pl SetEnv MOJO_MODE "production" RewriteEngine On RewriteBase /api/ RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{DOCUMENT_ROOT}/../api/$1/app.pl -f RewriteRule ^(.*?)/.* $1/app.pl/api/$0 [L]