From 6336715b989fdf3000b3c71f00cfcf8afbf4e742 Mon Sep 17 00:00:00 2001 From: Hyperling Date: Sun, 31 Jan 2021 13:55:18 -0600 Subject: [PATCH] Change shell chmod to file module. --- tasks/hardness_check_lynis.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tasks/hardness_check_lynis.yml b/tasks/hardness_check_lynis.yml index 54d2d5f..cf5cea5 100644 --- a/tasks/hardness_check_lynis.yml +++ b/tasks/hardness_check_lynis.yml @@ -9,4 +9,6 @@ shell: "{{ lynis_install_dir }}/lynis --no-colors audit system > {{ lynis_report }} 2>&1" - name: Make Lynis Report Readable - shell: chmod 444 "{{ lynis_report }}" \ No newline at end of file + ansible.builtin.file: + path: "{{ lynis_report }}" + mode: '0444' \ No newline at end of file