4
0
Fork 0

Added new prelim interactive_user_home

Signed-off-by: Mark Bolwell <mark.bollyuk@gmail.com>
This commit is contained in:
Mark Bolwell 2023-01-19 16:25:34 +00:00
parent 499b67ceb2
commit fbe238091b
No known key found for this signature in database
GPG key ID: 1DE02A772D0908F9

View file

@ -12,6 +12,13 @@
- level1-workstation
- users
- name: "PRELIM | Interactive User accounts"
ansible.builtin.shell: 'cat /etc/passwd | grep -Ev "nologin|/sbin" | cut -d: -f6'
changed_when: false
register: interactive_users_home
tags:
- always
- name: "PRELIM | Gather accounts with empty password fields"
ansible.builtin.shell: "cat /etc/shadow | awk -F: '($2 == \"\" ) {j++;print $1; } END {exit j}'"
changed_when: false