1
0
Fork 0

Initial base playbooks

Signed-off-by: Nis Wechselberg <enbewe@enbewe.de>
This commit is contained in:
Nis Wechselberg 2024-06-17 16:45:02 +02:00
parent 9c51597396
commit dd603044fc
Signed by: enbewe
GPG key ID: 7B25171F921B9E57
11 changed files with 305 additions and 0 deletions

14
playbooks/known_hosts.yml Normal file
View file

@ -0,0 +1,14 @@
---
- name: 'Install SSH keys as known hosts'
hosts: 'all'
serial: 1
gather_facts: false
tasks:
- name: 'Register host key'
delegate_to: 'localhost'
throttle: 1
when: 'ssh_ed25519'
ansible.builtin.known_hosts:
name: '{{ inventory_hostname }}'
key: '{{ inventory_hostname }} ssh-ed25519 {{ ssh_ed25519 }}'