Disclaimer:
This playbook and its roles are only tested for Ubuntu 22.04 systems!
A role to harden your Ubuntu 22.04 system.
This role was built using CIS Ubuntu Linux 22.04 LTS Benchmark v1.0.0 as a guide.
Task files contain configuration for:
- AppArmor
- Auditd
- Cron
- Iptables
- journald
- sshd
- sysctl
- timesyncd
- unnecessary services
This role installs the latest docker and docker compose versions.
It also adds the specified users to the docker group.
Install the requirements:
ansible-galaxy install -r requirements.ymlEdit the inventory file as needed.
Edit the defaults variables per role as needed.
Execute the whole playbook or selected tasks by setting tags:
e.g.
ansible-playbook -i inventory vps.yml
ansible-playbook -i inventory vps.yml --tags "sysctl,docker"