evolinux-base: apt/listchanges with lineinfile
Ansible < 2.1 puts an extra space around "=" It might be a problem for APT. Until we can use Ansible >= 2.1 we use lineinfile instead even if it less precise (doesn't manage sections)
This commit is contained in:
parent
4b9d5bf6fd
commit
b2c6847019
|
@ -49,12 +49,13 @@
|
||||||
backup: yes
|
backup: yes
|
||||||
mode: 0640
|
mode: 0640
|
||||||
|
|
||||||
|
# TODO: use ini_file when Ansible > 2.1 (no_extra_spaces: yes)
|
||||||
|
|
||||||
- name: Configure Listchanges
|
- name: Configure Listchanges
|
||||||
ini_file:
|
lineinfile:
|
||||||
dest: /etc/apt/listchanges.conf
|
dest: /etc/apt/listchanges.conf
|
||||||
section: apt
|
regexp: '^{{ item.option }}\s*='
|
||||||
option: "{{ item.option }}"
|
line: "{{ item.option }}={{ item.value }}"
|
||||||
value: "{{ item.value }}"
|
|
||||||
with_items:
|
with_items:
|
||||||
- { option: "confirm", value: "1" }
|
- { option: "confirm", value: "1" }
|
||||||
- { option: "which", value: "both" }
|
- { option: "which", value: "both" }
|
||||||
|
|
Loading…
Reference in a new issue