env-ansible/tasks/hardness_check_lynis.yml

16 lines
358 B
YAML
Raw Normal View History

---
- name: Install Lynis
2021-01-31 17:17:14 -06:00
git:
repo: https://github.com/CISOfy/lynis
dest: "{{ lynis_install_dir }}"
clone: yes
force: yes
- name: Run Lynis Audit System
shell: "{{ lynis_install_dir }}/lynis --no-colors audit system > {{ lynis_report }} 2>&1"
- name: Make Lynis Report Readable
2021-01-31 17:17:14 -06:00
file:
2021-01-31 13:55:18 -06:00
path: "{{ lynis_report }}"
mode: '0444'