No description
| Filename | Latest commit message | Latest commit date |
|---|---|---|
| defaults | ||
| meta | ||
| tasks | ||
| LICENSE | ||
| README.md | ||
ansible-role-ntopng
An Ansible role for deploying ntopng with Podman.
The role follows ntop's container guidance:
- use host networking by default so ntopng can capture host-interface traffic
- persist
/var/lib/ntopng - persist
/var/lib/redis, because ntopng stores configuration in Redis - optionally mount
/etc/ntopng.licensefor non-community editions
References:
- https://hub.docker.com/r/ntop/ntopng
- https://www.ntop.org/best-practices-for-using-ntop-tools-on-containers/
Task Configuration
- name: Setup ntopng
hosts: somehost
become: true
roles:
- role: ntopng
ntopng_interface: enp1s0
ntopng_license_file: /etc/ntopng.license
The web UI listens on port 3000 when ntopng_network is host. The default
credentials for a new ntopng deployment are admin / admin.
Common Options
ntopng_image: docker.io/ntop/ntopng
ntopng_image_tag: latest
ntopng_network: host
ntopng_interface: eth0
ntopng_http_port: 3000
ntopng_license_file: /etc/ntopng.license
ntopng_extra_args:
- --community
Use ntopng_extra_args for ntopng command-line flags. The role always passes
-i {{ ntopng_interface }} first.
Deployment and Removal
Services must be stopped as the respective user or another means to acquire the correct user scope for systemd.
systemctl --user stop container-ntopng.service
Deploy:
ansible-playbook -i hosts site.yml --tags=ntopng --limit=somehost
Remove:
ansible-playbook -i hosts site.yml --tags=ntopng --extra-vars "container_state=absent" --limit=somehost