fnzv.auditbeat
Ansible Role: auditbeat
This role installs auditbeat on Ubuntu 16.04 (Xenial).
Requirements
You need Ansible version 2.4 or higher to use this role.
Role Variables
Most variables are set in defaults/main.yml
.
Example Playbook
To run with default settings:
- hosts: all
roles:
- { role: ansible-auditbeat }
Testing
You can test this role using Molecule.
You can install Molecule or use docker-compose run --rm molecule
to start a local Docker container with the entercloudsuite/molecule image, which allows you to use molecule
.
Steps to test:
- Run
molecule create
to set up a Docker container. - Use
molecule login
to access the running container. - Edit the role's files as needed.
- Add any extra roles you need in
molecule/default/requirements.yml
. - Modify
molecule/default/playbook.yml
. - Create infrastructure tests in the
molecule/default/tests
folder using the goos verifier. - When you're ready, use
molecule converge
to run the Ansible Playbook andmolecule verify
to run the tests. The converge step will check the role's syntax. - To stop and remove the Docker container, use
molecule destroy
.
You can also run all steps at once using molecule test
.
To run this role on a VM, use the playbook_deploy.yml
file with a command like: ansible-playbook ansible-auditbeat/molecule/default/playbook_deploy.yml -i VM_IP_OR_FQDN, -u ubuntu --private-key private.pem
.
License
MIT