From: Stephen Gran Date: Sat, 14 Nov 2009 19:21:40 +0000 (+0000) Subject: deal with different data structure in authorized_keys template X-Git-Url: https://git.adam-barratt.org.uk/?a=commitdiff_plain;h=886c3cbf95ede0590b637e130c4012963b78f9f6;p=mirror%2Fdsa-puppet.git deal with different data structure in authorized_keys template Signed-off-by: Stephen Gran --- diff --git a/modules/ssh/templates/authorized_keys.erb b/modules/ssh/templates/authorized_keys.erb index 1a22ba7fa..d0af2f21a 100644 --- a/modules/ssh/templates/authorized_keys.erb +++ b/modules/ssh/templates/authorized_keys.erb @@ -9,7 +9,7 @@ hosterkeys when "argento.debian.org" then "ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAIEA5q3myoIMyqv6HhAR4lxaO7OXLRkKqUlEHeCudksc7ZAVSqJAQ3ODn8zAoY34duvRUOq7xpGcl8gXWujCtcUWDZCxNsxz+iWI/3oEaZly/ZTJXtoYUjmUodV7PJ8DbokiJGUIc1s3MiGa9QYam0D28TT8jWCJFcthC7VS61GBgT8= /Users/manon/.ssh/id_rsa - Manon Goo Local Admin" when "bartok.debian.org" then out = '' - keyinfo.each do |node| + keyinfo.keys.sort.each do |node| out += '# ' + node['hostname'].to_s + ' command="/usr/lib/da-backup/da-backup-ssh-wrap ' + node['hostname'].to_s + '",no-port-forwarding,no-X11-forwarding,no-agent-forwarding,from="' + node['ipHostNumber'].join(',') + '" ' + node['sshRSAHostKey'].to_s + '