We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
On minimized Ubuntu 22.04 there is no syslog group, so task [devsec.hardening.os_hardening : Harden permissions for directory of mount /var/log fails.
syslog
[devsec.hardening.os_hardening : Harden permissions for directory of mount /var/log
- hosts: all roles: - name: devsec.hardening.os_hardening
TASK [devsec.hardening.os_hardening : Harden permissions for directory of mount /var/log] *********************************************************************** fatal: [ubtest]: FAILED! => {"changed": false, "gid": 0, "group": "root", "mode": "0755", "msg": "chgrp failed: failed to look up group syslog", "owner": "root", "path": "/var/log", "size": 4096, "state": "directory", "uid": 0}
If there is no syslog on the system, I guess the task should be skipped.
Fresh install:
ansible [core 2.16.1] config file = /Users/bl4ko/Projects/ansible/ansible.cfg configured module search path = ['/Users/bl4ko/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules'] ansible python module location = /opt/homebrew/Cellar/ansible/9.1.0/libexec/lib/python3.12/site-packages/ansible ansible collection location = /Users/bl4ko/.ansible/collections:/usr/share/ansible/collections executable location = /opt/homebrew/bin/ansible python version = 3.12.1 (main, Dec 7 2023, 20:45:44) [Clang 15.0.0 (clang-1500.0.40.1)] (/opt/homebrew/Cellar/ansible/9.1.0/libexec/bin/python) jinja version = 3.1.3 libyaml = True
v9.0.0
...
The text was updated successfully, but these errors were encountered:
Solved with the os_mnt_var_log_group var which is missing in the docs.
Sorry, something went wrong.
The reason that it's missing is that its not supposed to be changed (that's why its in the vars and not in the defaults).
vars
defaults
So rather it's a possible bug that we set the group to syslog but the group does not exist and we should check that.
No branches or pull requests
Description
On minimized Ubuntu 22.04 there is no
syslog
group, so task[devsec.hardening.os_hardening : Harden permissions for directory of mount /var/log
fails.Reproduction steps
Current Behavior
Expected Behavior
If there is no syslog on the system, I guess the task should be skipped.
OS / Environment
Fresh install:
Ansible Version
Collection Version
Additional information
...
The text was updated successfully, but these errors were encountered: