ansible core 2.1
When using win_lineinfile module and the `create: yes` option it seems it
should create a new file. it fails the same as if create:yes is not
specified.
- hosts: all
tasks:
- name: win_lineinfile test
win_lineinfile:
dest: 'c:\temp\ansible-windows.log'
create: yes
line: '{{ ansible_hostname }}-{{ ansible_date_time.iso8601 }}'
regexp: '{{ ansible_hostname }}-'
state: present
If dest doesn't exist it fails. Guessing I am doing something wrong?
--
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/7e95bef5-7a1c-4e1c-a677-83361863e028%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.