blse2-public/common-debian/templates/etc/ssh/ssh_known_hosts.j2

9 lines
362 B
Django/Jinja

# SSH remote allowed hosts
# {{ ansible_managed }}
{% if hostbased_auth is defined and hostbased_auth %}
{% for entry in hostbased_auth %}
{{ hostvars[entry]['ansible_hostname'] }},{{ hostvars[entry]['ansible_fqdn'] }},{{ hostvars[entry]['inventory_hostname'] }} ssh-ed25519 {{ hostvars[entry]['ansible_ssh_host_key_ed25519_public'] }}
{% endfor %}
{% endif %}