ansible-role-nextcloud/templates/apache2/custom.conf.j2

17 lines
444 B
Django/Jinja

# {{ ansible_managed }}
{% if item.alias is defined %}
{% for alias in item.alias %}
ServerAlias {{ alias }}
{% endfor %}
{% endif %}
{% if item.config.hiddenservice is defined and item.config.hiddenservice %}
ServerAlias {{ hiddenservice_address.stdout }}
<IfModule mod_headers.c>
<If "%{SERVER_NAME} == '{{ item.name }}'">
Header set Onion-Location "http://{{ hiddenservice_address.stdout }}"
</If>
</IfModule>
{% endif %}