forked from evolix/ansible-roles
Fix ssh LogLevel
* the directive can be present but commented * the version comparison was wrong
This commit is contained in:
parent
43e9f69314
commit
adc3bd7a93
|
@ -44,11 +44,11 @@
|
||||||
- name: Set log level to verbose (for Debian >= 9)
|
- name: Set log level to verbose (for Debian >= 9)
|
||||||
replace:
|
replace:
|
||||||
dest: /etc/ssh/sshd_config
|
dest: /etc/ssh/sshd_config
|
||||||
regexp: '^LogLevel [A-Z]+'
|
regexp: '^#?LogLevel [A-Z]+'
|
||||||
replace: "LogLevel VERBOSE"
|
replace: "LogLevel VERBOSE"
|
||||||
notify: reload sshd
|
notify: reload sshd
|
||||||
when:
|
when:
|
||||||
- ansible_distribution == "Debian"
|
- ansible_distribution == "Debian"
|
||||||
- ansible_distribution_major_version | version_compare('9.0', '>=')
|
- ansible_distribution_major_version | version_compare('9', '>=')
|
||||||
|
|
||||||
- meta: flush_handlers
|
- meta: flush_handlers
|
||||||
|
|
Loading…
Reference in a new issue