mirror of
https://github.com/willshersystems/ansible-sshd
synced 2024-11-10 05:33:29 +01:00
tests: Do not use ed25519 keys as they are not available in RHEL6
This commit is contained in:
parent
70a9daf916
commit
fd144194e6
1 changed files with 6 additions and 6 deletions
|
@ -4,14 +4,14 @@
|
||||||
__sshd_test_backup_files:
|
__sshd_test_backup_files:
|
||||||
- /etc/ssh/sshd_config
|
- /etc/ssh/sshd_config
|
||||||
- /etc/ssh/sshd_config.d/00-ansible_system_role.conf
|
- /etc/ssh/sshd_config.d/00-ansible_system_role.conf
|
||||||
- /tmp/ssh_host_ed25519_key
|
- /tmp/ssh_host_rsa_key2
|
||||||
tasks:
|
tasks:
|
||||||
- name: "Backup configuration files"
|
- name: "Backup configuration files"
|
||||||
include_tasks: tasks/backup.yml
|
include_tasks: tasks/backup.yml
|
||||||
|
|
||||||
- name: Remove host key before the test
|
- name: Remove host key before the test
|
||||||
file:
|
file:
|
||||||
path: /tmp/ssh_host_ed25519_key
|
path: /tmp/ssh_host_rsa_key2
|
||||||
state: absent
|
state: absent
|
||||||
|
|
||||||
- name: Ensure group 'nobody' exists
|
- name: Ensure group 'nobody' exists
|
||||||
|
@ -36,7 +36,7 @@
|
||||||
sshd_hostkey_mode: "0664"
|
sshd_hostkey_mode: "0664"
|
||||||
sshd:
|
sshd:
|
||||||
HostKey:
|
HostKey:
|
||||||
- /tmp/ssh_host_ed25519_key
|
- /tmp/ssh_host_rsa_key2
|
||||||
|
|
||||||
- name: Verify the options are correctly set
|
- name: Verify the options are correctly set
|
||||||
vars:
|
vars:
|
||||||
|
@ -55,17 +55,17 @@
|
||||||
register: config
|
register: config
|
||||||
|
|
||||||
- stat:
|
- stat:
|
||||||
path: /tmp/ssh_host_ed25519_key
|
path: /tmp/ssh_host_rsa_key2
|
||||||
register: privkey
|
register: privkey
|
||||||
|
|
||||||
- stat:
|
- stat:
|
||||||
path: /tmp/ssh_host_ed25519_key.pub
|
path: /tmp/ssh_host_rsa_key2.pub
|
||||||
register: pubkey
|
register: pubkey
|
||||||
|
|
||||||
- name: Check the options are in configuration file
|
- name: Check the options are in configuration file
|
||||||
assert:
|
assert:
|
||||||
that:
|
that:
|
||||||
- "'HostKey /tmp/ssh_host_ed25519_key' in config.content | b64decode"
|
- "'HostKey /tmp/ssh_host_rsa_key2' in config.content | b64decode"
|
||||||
|
|
||||||
- name: Check the generated host key has requested properties
|
- name: Check the generated host key has requested properties
|
||||||
assert:
|
assert:
|
||||||
|
|
Loading…
Reference in a new issue