diff --git a/templates/ssh_config.j2 b/templates/ssh_config.j2 index 0662396..dc0e350 100644 --- a/templates/ssh_config.j2 +++ b/templates/ssh_config.j2 @@ -1,3 +1,5 @@ +# {{ ansible_managed }} + # Ensure KnownHosts are unreadable if leaked - it is otherwise easier to know which hosts your keys have access to. HashKnownHosts yes # Host keys the client accepts - order here is honored by OpenSSH diff --git a/templates/ssh_root_authorized_keys.j2 b/templates/ssh_root_authorized_keys.j2 index ab7f10b..71d2668 100644 --- a/templates/ssh_root_authorized_keys.j2 +++ b/templates/ssh_root_authorized_keys.j2 @@ -1,4 +1,4 @@ -### AUTOGENERATED do not edit! edit /inventory/group_vars/all.yml in ansible ### +# {{ ansible_managed }} {% for name, keys in admin_ssh_keys.items() %} #{{ name }} diff --git a/templates/ssh_sshd_config.j2 b/templates/ssh_sshd_config.j2 index d30d933..323bf6e 100644 --- a/templates/ssh_sshd_config.j2 +++ b/templates/ssh_sshd_config.j2 @@ -1,4 +1,4 @@ -# Package generated configuration file +# {{ ansible_managed }} # See the sshd_config(5) manpage for details # What ports, IPs and protocols we listen for @@ -49,9 +49,6 @@ Subsystem sftp internal-sftp UsePam yes # needed to create home dirs with an ldap login -AuthorizedKeysCommand /etc/ssh/ldap_sshpubkey.sh -AuthorizedKeysCommandUser sshd - AuthorizedKeysFile /root/.ssh/authorized_keys MaxAuthTries 10