CSC Ansible Playbooks
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.

16 lines
564 B

- hosts: all
gather_facts: no
remote_user: root
- name: generate ed25519 key
shell: ssh-keygen -t ed25519 -f /etc/ssh/ssh_host_ed25519_key -N '' < /dev/null
creates: /etc/ssh/ssh_host_ed25519_key
- name: copy ssh config
copy: src={{ item.src }} dest={{ item.dest }} backup=yes
- { src: 'files/ssh_config', dest: '/etc/ssh/ssh_config' }
- { src: 'files/sshd_config', dest: '/etc/ssh/sshd_config' }
- name: restart sshd
service: name=ssh state=restarted