#====================================================================
# Apache configuration for LemonLDAP::NG Handler
#====================================================================

# Load LemonLDAP::NG Handler
PerlOptions +GlobalRequest
PerlModule Lemonldap::NG::Handler::ApacheMP2
PerlModule Lemonldap::NG::Handler::ApacheMP2::Menu

# Common error page and security parameters
#ErrorDocument 403 http://auth.{$DomainName}/?lmError=403
#ErrorDocument 500 http://auth.{$DomainName}/?lmError=500


# Configuration reload mechanism (only 1 per physical server is
# needed): choose your URL to avoid restarting Apache when
# configuration change
# Dummy Alias so apache allows access to /lm-reload
Alias /lm-reload /etc/httpd/proxy/proxy.pac
<Location /lm-reload>
    SSLRequireSSL on
    Require ip {"$LocalIP $localAccess $externalSSLAccess";}
    SetHandler perl-script
    PerlResponseHandler Lemonldap::NG::Handler::ApacheMP2->reload
</Location>

# Configuration reload mechanism (only 1 per physical server is
# needed): choose your URL to avoid restarting Apache when
# configuration change
#<Location /reload>
#    Require ip {"$LocalIP $localAccess $externalSSLAccess";}
#    SetHandler perl-script
#    PerlResponseHandler Lemonldap::NG::Handler::ApacheMP2->reload
#</Location>

# Uncomment this to activate status module
#<Location /status>
#    Require ip 127.0.0.0/8
#    PerlHeaderParserHandler Lemonldap::NG::Handler->status
#</Location>

