Disallow ssh passwords

This commit is contained in:
Reynir Björnsson 2020-12-13 15:25:21 +01:00
parent e9f1d800a1
commit c266a55213
2 changed files with 7 additions and 0 deletions

View file

@ -2,3 +2,4 @@
- import_tasks: upgrade.yml
- import_tasks: base.yml
- import_tasks: users.yml
- import_tasks: sshd.yml

View file

@ -0,0 +1,6 @@
---
- name: Disallow ssh password login
lineinfile:
path: /etc/ssh/sshd_config
line: "PasswordAuthentication no"
regexp: "^#?PasswordAuthentication "