Added playbook to enable Touch ID authentication for 'sudo', fixed Ansible's KB

This commit is contained in:
Michele Cereda
2022-07-04 12:10:24 +02:00
parent 9ebaa941fa
commit 66bedfcc46
2 changed files with 58 additions and 7 deletions

View File

@@ -0,0 +1,19 @@
---
- name: Enable Touch ID for sudo authentication in the terminal
tags:
- configuration
- enable
- sudo
- terminal
- touch-id
hosts: all
tasks:
- name: Enable Touch ID's PAM modules
become: true
ansible.builtin.lineinfile:
path: /etc/pam.d/sudo
line: 'auth sufficient pam_tid.so'
insertafter: '^# sudo: auth account password session$'
mode: 'ugo=r'
backup: true