Add validation on sshd-config changes
This commit is contained in:
parent
5a3e1bd8ec
commit
789282c82b
1 changed files with 1 additions and 0 deletions
|
@ -108,6 +108,7 @@
|
||||||
path: /etc/ssh/sshd_config
|
path: /etc/ssh/sshd_config
|
||||||
regexp: "{{ item.regexp }}"
|
regexp: "{{ item.regexp }}"
|
||||||
line: "{{ item.line }}"
|
line: "{{ item.line }}"
|
||||||
|
validate: "/usr/sbin/sshd -t -f %s"
|
||||||
with_items:
|
with_items:
|
||||||
- regexp: '^#?Port'
|
- regexp: '^#?Port'
|
||||||
line: 'Port {{ ssh_port }}'
|
line: 'Port {{ ssh_port }}'
|
||||||
|
|
Loading…
Add table
Reference in a new issue