mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2026-11-08 03:38:23 +00:00
fix(roles): satisfy the include existence and pure-guard lints of the Discourse and XWiki bundles
tests/integration/roles flagged two of today's bundles: the Discourse legacy-checkout guard lived in a block inside the included file, so the file loaded even when the guard was false; it now sits on the include_tasks in 03_launcher.yml and the file holds the two tasks with become. XWiki's utils/extensions_ready.yml included _check_extension_via_groovy.yml by bare name from tasks/utils/; it now uses {{ role_path }}/tasks/..., which resolves under include_tasks and include_role tasks_from alike (a bare ../ breaks under tasks_from, as the XWiki replay harness showed).
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
1 parent
7751f6660d
commit
11c2d8dcd3
3 files changed
+17
-18
No files matched your search
@@ -5,6 +5,7 @@
|
||||
|
||||
- name: "🧹 Retire the launcher checkout of the URL-named layout"
|
||||
include_tasks: launcher/legacy_checkout.yml
|
||||
when: (DISCOURSE_REPOSITORY_LEGACY_RELPATH | split('/') | first) not in ['..', DISCOURSE_REPOSITORY_DIR | basename]
|
||||
|
||||
- name: ⬇️ Pull Discourse docker repository
|
||||
git:
|
||||
|
||||
@@ -1,20 +1,18 @@
|
||||
---
|
||||
- name: "🛡️ Touch only the URL-named tree beside the new checkout"
|
||||
when: (DISCOURSE_REPOSITORY_LEGACY_RELPATH | split('/') | first) not in ['..', DISCOURSE_REPOSITORY_DIR | basename]
|
||||
- name: "🗑️ Remove the URL-named launcher checkout"
|
||||
ansible.builtin.file:
|
||||
path: "{{ [ DISCOURSE_SERVICES_DIR, DISCOURSE_REPOSITORY_LEGACY_RELPATH ] | path_join }}"
|
||||
state: absent
|
||||
become: true
|
||||
block:
|
||||
- name: "🗑️ Remove the URL-named launcher checkout"
|
||||
ansible.builtin.file:
|
||||
path: "{{ [ DISCOURSE_SERVICES_DIR, DISCOURSE_REPOSITORY_LEGACY_RELPATH ] | path_join }}"
|
||||
state: absent
|
||||
|
||||
- name: "🗑️ Prune the emptied parents of the URL-named checkout"
|
||||
ansible.builtin.command:
|
||||
argv:
|
||||
- rmdir
|
||||
- --ignore-fail-on-non-empty
|
||||
- --parents
|
||||
- "{{ DISCOURSE_REPOSITORY_LEGACY_RELPATH | dirname }}"
|
||||
chdir: "{{ DISCOURSE_SERVICES_DIR }}"
|
||||
removes: "{{ [ DISCOURSE_SERVICES_DIR, DISCOURSE_REPOSITORY_LEGACY_RELPATH | dirname ] | path_join }}"
|
||||
when: DISCOURSE_REPOSITORY_LEGACY_RELPATH is search('/')
|
||||
- name: "🗑️ Prune the emptied parents of the URL-named checkout"
|
||||
ansible.builtin.command:
|
||||
argv:
|
||||
- rmdir
|
||||
- --ignore-fail-on-non-empty
|
||||
- --parents
|
||||
- "{{ DISCOURSE_REPOSITORY_LEGACY_RELPATH | dirname }}"
|
||||
chdir: "{{ DISCOURSE_SERVICES_DIR }}"
|
||||
removes: "{{ [ DISCOURSE_SERVICES_DIR, DISCOURSE_REPOSITORY_LEGACY_RELPATH | dirname ] | path_join }}"
|
||||
become: true
|
||||
when: DISCOURSE_REPOSITORY_LEGACY_RELPATH is search('/')
|
||||
@@ -41,7 +41,7 @@
|
||||
and _xwiki_running_core.content is search('<version>' ~ (XWIKI_CORE_VERSION | regex_escape) ~ '</version>') }}
|
||||
|
||||
- name: "✅ XWIKI | Check the running wiki's add-ons against their pins"
|
||||
include_tasks: _check_extension_via_groovy.yml
|
||||
include_tasks: "{{ role_path }}/tasks/_check_extension_via_groovy.yml"
|
||||
loop: "{{ XWIKI_PLUGINS }}"
|
||||
loop_control:
|
||||
loop_var: plugin
|
||||
|
||||
Reference in new issue
Block a user