Re: [ansible-project] 'copy' TASK won't copy a file - eventhough reporting 'ok'

2022-07-14 Thread Brian Coca
always use -vvv before even asking a question, then also post that info here.

I suspect that the file is there and that ansible is comparing the
checksums and seeing they are the same and that it does not need to
make the copy.



-- 
--
Brian Coca

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-project+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CACVha7f2iuXf%2BYQ6ww0ff41%3Dmy0%2B%3DerKCzsEupBrrHdo2B-tig%40mail.gmail.com.


Re: [ansible-project] 'copy' TASK won't copy a file - eventhough reporting 'ok'

2022-07-14 Thread Stefan Hornburg (Racke)

On 14/07/2022 15:41, dulhaver via Ansible Project wrote:

I have a TASK that should copy *~/files/repo_pgbackrest.conf* to the remote as 
*/etc/pgbackrest/pgbackrest.conf* (note the differing file name).
however, despite that fact playbook exection returns an 'ok' an that TASK, the 
file is *not pushed* to the remote.
==
- name: install preps - push config file
   copy:
     src: files/repo_pgbackrest.conf # was: repo_pgbackrest.conf
     dest: " {{ item }} "
     mode: '0640'
owner: pgbackrest
     group: pgbackrest
   become: true
   loop:
     - /etc/pgbackrest/pgbackrest.conf
==
Knowing that sometimes things only work after several re-runs I executed this 
about 5 times with the exact same, unwanted behavior.
So ... what am I doing wrong here?


My suspicion would be that you are looking at the wrong target.

Regards
   Racke


--
You received this message because you are subscribed to the Google Groups "Ansible 
Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email to 
ansible-project+unsubscr...@googlegroups.com 
.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/1699810404.552239.1657806094344%40office.mailbox.org
 
.



--
Automation expert - Ansible and friends
Linux administrator & Debian maintainer
Perl Dancer & conference hopper

--
You received this message because you are subscribed to the Google Groups "Ansible 
Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-project+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/3598550b-2738-e7de-024b-59326633d7a4%40linuxia.de.


[ansible-project] 'copy' TASK won't copy a file - eventhough reporting 'ok'

2022-07-14 Thread dulhaver via Ansible Project
I have a TASK that should copy ~/files/repo_pgbackrest.conf to the remote as 
/etc/pgbackrest/pgbackrest.conf (note the differing file name).
 
however, despite that fact playbook exection returns an 'ok' an that TASK, the 
file is not pushed to the remote.
 
==
 
- name: install preps - push config file
  copy:
src: files/repo_pgbackrest.conf # was: repo_pgbackrest.conf
dest: " {{ item }} "
mode: '0640'
owner: pgbackrest
group: pgbackrest
  become: true
  loop:
- /etc/pgbackrest/pgbackrest.conf
 
==
 
Knowing that sometimes things only work after several re-runs I executed this 
about 5 times with the exact same, unwanted behavior.
 
So ... what am I doing wrong here? 

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-project+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/1699810404.552239.1657806094344%40office.mailbox.org.