mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2026-11-06 10:59:59 +00:00
A per-item boolean guard carried as a data field named 'when' must hold {{ EXPR }} so the consumer can template it to a real bool; but ansible-core 2.21+ then flags 'conditionals surrounded by templating delimiters'. Rename the data field to 'condition' (a data field may legitimately hold {{ }}) so no genuine conditional carries {{ }}. Also wraps the four previously-bare listmonk entries, which were silently always-False, so those settings now apply when enabled.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
32 lines
1.0 KiB
YAML
32 lines
1.0 KiB
YAML
---
|
|
- name: "✅ MEDIAWIKI | Ensure required host directories exist"
|
|
ansible.builtin.file:
|
|
path: "{{ item }}"
|
|
state: directory
|
|
mode: "0755"
|
|
loop:
|
|
- "{{ MEDIAWIKI_LOCAL_MOUNT_DIR }}"
|
|
- "{{ MEDIAWIKI_CONFIG_DIR }}"
|
|
|
|
- name: "📄 MEDIAWIKI | Render host-side PHP config files"
|
|
ansible.builtin.include_tasks:
|
|
file: "{{ lookup('path_absolute', 'roles/sys-svc-compose/tasks/utils/render_replicated_templates.yml') }}"
|
|
vars:
|
|
role_templates:
|
|
- src: "oidc.php.j2"
|
|
dest: "{{ MEDIAWIKI_LOCAL_MOUNT_DIR }}/oidc.php"
|
|
owner: "root"
|
|
group: "{{ MEDIAWIKI_USER_GID }}"
|
|
mode: "0640"
|
|
condition: "{{ MEDIAWIKI_OIDC_ENABLED | bool }}"
|
|
- src: "debug.php.j2"
|
|
dest: "{{ MEDIAWIKI_LOCAL_MOUNT_DIR }}/debug.php"
|
|
owner: "root"
|
|
group: "{{ MEDIAWIKI_USER_GID }}"
|
|
mode: "0640"
|
|
- src: "LocalSettings.php.j2"
|
|
dest: "{{ MEDIAWIKI_LOCALSETTINGS_HOST_PATH }}"
|
|
owner: "root"
|
|
group: "{{ MEDIAWIKI_USER_GID }}"
|
|
mode: "0640"
|