diff --git a/playbooks/bootstrap/templates/bastion/root/.ssh/known_hosts.j2 b/playbooks/bootstrap/templates/bastion/root/.ssh/known_hosts.j2 index 227fe24..daea73a 100644 --- a/playbooks/bootstrap/templates/bastion/root/.ssh/known_hosts.j2 +++ b/playbooks/bootstrap/templates/bastion/root/.ssh/known_hosts.j2 @@ -1,7 +1,7 @@ # This file is generated by Ansible # DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN # -{% for host in groups['all'] %} +{% for host in groups['all']|sort %} {% if hostvars[host].ansible_host is defined %} {% if hostvars[host].ansible_ssh_host_key_ed25519_public is defined %} {{ hostvars[host].ansible_hostname }},{{ hostvars[host].ansible_host }} ssh-ed25519 {{ hostvars[host].ansible_ssh_host_key_ed25519_public }}