buluma.lynis
Ansible role lynis
This role installs and sets up Lynis on your system.
GitHub | Version | Issues | Pull Requests | Downloads |
---|---|---|---|---|
Example Playbook
Here’s an example taken from molecule/default/converge.yml
. It is tested with every update, pull request, and release.
---
- name: Converge
hosts: all
become: true
gather_facts: true
pre_tasks:
- name: Update apt cache.
apt: update_cache=yes cache_valid_time=600
when: ansible_os_family == 'Debian'
changed_when: false
roles:
- role: buluma.cron
- role: buluma.git
- role: buluma.lynis
Before using this role, your machine needs preparation. In Continuous Integration (CI), this is done with molecule/default/prepare.yml
:
---
- name: Prepare
hosts: all
gather_facts: false
become: true
roles:
- role: buluma.bootstrap
For more details, see a full guide and examples on how to use these roles.
Role Variables
Default values for the variables are located in defaults/main.yml
:
---
# default settings for lynis
# Installation location for lynis
lynis_destination: "/tmp/lynis"
# Version to install
lynis_version: "3.0.6"
# Where to store the report output.
lynis_output: "{{ lynis_destination }}/{{ ansible_date_time.date }}-audit_system.txt"
# Should lynis run when the playbook executes?
lynis_run_now: true
# Should this be scheduled as a recurring job?
lynis_cronjob: true
Requirements
- Python packages mentioned in requirements.txt.
State of Used Roles
The following roles help prepare a system. You can use another method to prepare your system.
Requirement | GitHub | Version |
---|---|---|
buluma.bootstrap | ||
buluma.cron | ||
buluma.git |
Context
This role works with other compatible roles. Check out the documentation for these roles for more information.
Here is a summary of related roles:
Compatibility
This role has been tested with the following container images:
Container | Tags |
---|---|
Amazon | all |
EL | 8, 9 |
Debian | all |
Fedora | all |
opensuse | all |
Ubuntu | all |
Kali | all |
You need at least Ansible version 2.12. Tests have been conducted on:
- The previous version.
- The current version.
- The development version.
If you encounter any issues, please report them on GitHub.
Changelog
View the Role History.
License
Released under the Apache-2.0 license.
Author Information
Created by Shadow Walker.
ansible-galaxy install buluma.lynis