4
0
Fork 0

fix: more readable condition and prevent skipping 0600 #173

Signed-off-by: rjacobs1990 <ricardojacobs20@gmail.com>
This commit is contained in:
rjacobs1990 2024-02-12 16:21:31 +01:00
parent 8652390beb
commit 742165cd72
No known key found for this signature in database
GPG key ID: EA7B6E324836CABC

View file

@ -13,7 +13,7 @@
- name: "4.2.3 | PATCH | Ensure permissions on all logfiles are configured | change permissions" - name: "4.2.3 | PATCH | Ensure permissions on all logfiles are configured | change permissions"
ansible.builtin.file: ansible.builtin.file:
path: "{{ item.path }}" path: "{{ item.path }}"
mode: "{{ '0640' if item.mode != '0600' else '0600' }}" mode: "{{ '0600' if item.mode == '0600' else '0640' }}"
loop: "{{ logfiles.files }}" loop: "{{ logfiles.files }}"
loop_control: loop_control:
label: "{{ item.path }}" label: "{{ item.path }}"