Below is the sample of the lineinfile module that I used. The first time
run the playbook, it successfully change the line with the new line.
However, after I run one more time the playbook, it still add the line at
the bottom of the file.
- name: Change abc
> lineinfile:
> dest: "{{ abc }}"
> state: present
> regexp: ' <column name="PARAM_VALUE">http://{{ ansible_fqdn
> }}:{{ wabc_port }}</column>'
> line: ' <column name="PARAM_VALUE">https://{{ ansible_fqdn
> }}:{{ abc_port_https }}</column>'
How should it works?
--
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/f38e0bc0-b858-485d-bff9-a31c51b37108%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.