diff options
| author | alex <alex@pdp7.net> | 2026-01-17 18:49:35 +0100 |
|---|---|---|
| committer | alex <alex@pdp7.net> | 2026-01-17 18:49:35 +0100 |
| commit | 92b4ee5268f96dc23cf632e674117540877efd96 (patch) | |
| tree | 6b6e66f9e27d25a83c0774975d775b0ebddf9c4a /infrastructure/roles/web/tasks/main.yaml | |
| parent | 762cfec4dae85dcf3ad76bcb02a1f8757e558f29 (diff) | |
Enable Gemini content negotiation, for indexes too
Diffstat (limited to 'infrastructure/roles/web/tasks/main.yaml')
| -rw-r--r-- | infrastructure/roles/web/tasks/main.yaml | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/infrastructure/roles/web/tasks/main.yaml b/infrastructure/roles/web/tasks/main.yaml index 6e18cfa..bfa56f7 100644 --- a/infrastructure/roles/web/tasks/main.yaml +++ b/infrastructure/roles/web/tasks/main.yaml @@ -55,3 +55,18 @@ RedirectMatch "^/$" "https://ñix.es/cgit/alex/ñix.es.git/about/" </VirtualHost> notify: restart web +- name: gemini + ansible.builtin.copy: + dest: /etc/apache2/conf-enabled/gemini.conf + content: | + AddType text/gemini .gmi + # With the default dir module configuration disabled, DirectoryIndex index enables multiviews for indexes. + # This means that you can have index.html and index.gmi and the client and server will negotiate which content to deliver. + DirectoryIndex index + LoadModule dir_module /usr/lib/apache2/modules/mod_dir.so + notify: restart web +- name: disable dir mod + ansible.builtin.command: + cmd: a2dismod -f dir + removes: /etc/apache2/mods-enabled/dir.conf + notify: restart web |
