...
Gitea Branch PR & Ansible Deployment / Check and Create PR (push) Successful in 11s
Gitea Branch PR & Ansible Deployment / Ansible Dry Run (benedikta) (push) Failing after 1m23s
Gitea Branch PR & Ansible Deployment / Ansible Dry Run (rikku) (push) Failing after 1m27s
Gitea Branch PR & Ansible Deployment / Ansible Dry Run (rinoa) (push) Failing after 1m28s
Gitea Branch PR & Ansible Deployment / PR Merge (push) Has been skipped
Gitea Branch PR & Ansible Deployment / Ansible Config Deployment (benedikta) (push) Has been skipped
Gitea Branch PR & Ansible Deployment / Ansible Config Deployment (rikku) (push) Has been skipped
Gitea Branch PR & Ansible Deployment / Ansible Config Deployment (rinoa) (push) Has been skipped

This commit is contained in:
2025-09-14 11:28:59 -04:00
parent 4e992ace0f
commit eff0d92488
+6 -7
View File
@@ -10,15 +10,16 @@
template_base_path: "{{ playbook_dir }}/../app-configs"
pre_tasks:
- name: Find all files for this host
- name: Find all files for all hosts (run once on localhost)
ansible.builtin.find:
paths: "{{ template_base_path }}/{{ inventory_hostname }}"
recurse: true
register: host_files
run_once: true # can remain run_once, finds files once for all hosts
delegate_to: localhost
run_once: true
changed_when: false
- name: Build list of unique destination directories
- name: Build list of unique destination directories per host
ansible.builtin.set_fact:
dest_dirs: >-
{{
@@ -31,7 +32,7 @@
| list
}}
changed_when: false
run_once: false
run_once: false # run per host, so host_vars are available
tasks:
- name: Ensure destination directories exist (unique set)
@@ -59,9 +60,7 @@
- name: Deploy static files (skip unchanged)
ansible.builtin.copy:
src: "{{ item.path }}"
dest: >-
{{ appdata_base_path }}/{{ item.path
| relpath(template_base_path ~ '/' ~ inventory_hostname) }}
dest: "{{ appdata_base_path }}/{{ item.path | relpath(template_base_path ~ '/' ~ inventory_hostname) }}"
mode: '0644'
remote_src: false
loop: "{{ host_files.files }}"