From 71c97de6fff9176fe5a85e2f839e118f2020a1f3 Mon Sep 17 00:00:00 2001 From: "Trez.One" Date: Sun, 31 Aug 2025 19:02:28 -0400 Subject: [PATCH] Tweaking Ansible playbook and Gitea workflow. --- .gitea/workflows/gitea_tar-valon_ansible_deploy.yml | 1 + tar-valon_config_deploy.yml | 7 ++++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/.gitea/workflows/gitea_tar-valon_ansible_deploy.yml b/.gitea/workflows/gitea_tar-valon_ansible_deploy.yml index d741084..52c8f3b 100644 --- a/.gitea/workflows/gitea_tar-valon_ansible_deploy.yml +++ b/.gitea/workflows/gitea_tar-valon_ansible_deploy.yml @@ -10,6 +10,7 @@ on: - 'inventory/hosts.yml' - 'host_vars/**' - 'group_vars/**' + - '**/tar-valon_config_deploy.yml' - '**/gitea_tar-valon_ansible_deploy.yml' env: diff --git a/tar-valon_config_deploy.yml b/tar-valon_config_deploy.yml index c799830..873d912 100644 --- a/tar-valon_config_deploy.yml +++ b/tar-valon_config_deploy.yml @@ -18,7 +18,7 @@ register: host_files delegate_to: localhost run_once: true - run_on_delegate: true + changed_when: false # ensures this task never shows as "changed" - name: Build list of unique destination directories ansible.builtin.set_fact: @@ -32,6 +32,7 @@ | unique | list }} + changed_when: false # computing vars does not constitute a change tasks: - name: Ensure destination directories exist (unique set) @@ -48,7 +49,7 @@ src: "{{ item.path }}" dest: >- {{ appdata_base_path }}/{{ item.path - | relpath(template_base_path + '/' + inventory_hostname) + | relpath(template_base_path ~ '/' ~ inventory_hostname) | regex_replace('\.j2$', '') }} mode: '0644' loop: "{{ host_files.files }}" @@ -61,7 +62,7 @@ src: "{{ item.path }}" dest: >- {{ appdata_base_path }}/{{ item.path - | relpath(template_base_path + '/' + inventory_hostname) }} + | relpath(template_base_path ~ '/' ~ inventory_hostname) }} mode: '0644' remote_src: false loop: "{{ host_files.files }}"