On 29. juni 2016 08:07, Werner Flamme wrote:
The module instead scans the file, and on the first run it behaves as I
expect, the line in the file is modified. On subsequent runs, one line
(per run) is added to the file (before EOF), so that I have multiple
lines containing "line".

Is this behaviour expected? How can I make a replacement only when
"regex" matches?

No, and you are not alone
https://github.com/ansible/ansible-modules-core/issues/3975

--
Kai Stian Olstad

--
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 [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/5773CB6C.8080109%40olstad.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to