This commit is contained in:
parent
1022fd7fb0
commit
fd3da4df78
3 changed files with 2 additions and 9 deletions
|
@ -11,7 +11,6 @@ jinja_environment:
|
|||
baseurl_abs: https://chaostreff.ch/
|
||||
baseurl: /
|
||||
spaceapi_proxy_endpoint: /spaceapi-proxy
|
||||
htaccess_language_redirect: no
|
||||
htaccess_spaceapi_proxy: yes
|
||||
|
||||
hackerspaces:
|
||||
|
|
|
@ -4,18 +4,12 @@ DirectoryIndex index.var index.html
|
|||
# Optional: Redirect to language specific subsite, rather than showing
|
||||
# language specific content at the root
|
||||
|
||||
{% if htaccess_language_redirect %}
|
||||
{%- for language in languages %}
|
||||
Redirect /index.{{ language }}.html /{{ language }}/
|
||||
{%- endfor %}
|
||||
{%- endif %}
|
||||
|
||||
{% if htaccess_spaceapi_proxy %}
|
||||
# SpaceAPI proxy service workaround for missing CORS headers
|
||||
RewriteEngine on
|
||||
{%- for space in hackerspaces %}
|
||||
{%- if 'spaceapi' in space %}
|
||||
RewriteRule ^/spaceapi-proxy{{ space.spaceapi }}$ {{ space.spaceapi.split('/', 2)[1] }}://{{ space.spaceapi.split('/', 2)[2] }} [P,L]
|
||||
RewriteRule ^spaceapi-proxy{{ space.spaceapi }}$ {{ space.spaceapi.split('/', 2)[1] }}://{{ space.spaceapi.split('/', 2)[2] }} [P,L]
|
||||
{%- endif %}
|
||||
{%- endfor %}
|
||||
{%- endif %}
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
URI: index; vary="language"
|
||||
|
||||
{% for language in languages %}
|
||||
URI: index.{{ language }}.html
|
||||
URI: {{ language }}/index.html
|
||||
Content-Type: text/html
|
||||
Content-Language: {{ language }}
|
||||
{% endfor %}
|
||||
|
|
Loading…
Reference in a new issue