{% if dokuwiki_alias is defined %}
Alias /{{ dokuwiki_alias }} {{ dokuwiki_root_dir }}/web
{% else %}
# No alias defined, create a vhost to access it
{% endif %}
AllowOverride All
Options FollowSymLinks
{% if dokuwiki_src_ip is defined %}
Require ip {{ dokuwiki_src_ip | join(' ') }}
{% else %}
Require all granted
{% endif %}
SetHandler "proxy:unix:/run/php-fpm/{{ dokuwiki_php_fpm_pool | default('dokuwiki_' + dokuwiki_id | string) }}.sock|fcgi://localhost"
Require all denied
{% if httpd_src_ip is defined and httpd_src_ip | length > 0 and '0.0.0.0/0' not in httpd_src_ip and dokuwiki_auth == 'authhttpldap' %}
RewriteEngine On
RewriteCond %{HTTP:Auth-User} ^(\w+)$
RewriteRule .* - [E=REMOTE_USER:%1]
{% endif %}
Require all denied
Require all denied
Require all denied
Require all denied