From c0f041410a24b5c57d9f0b6531f38dce036bbe0e Mon Sep 17 00:00:00 2001 From: Justin Findlay Date: Fri, 13 Mar 2015 11:52:43 -0600 Subject: [PATCH] check for ssh key comment Fixes #21603. --- salt/states/ssh_auth.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/salt/states/ssh_auth.py b/salt/states/ssh_auth.py index 1e6456c4b1..a60ea6c375 100644 --- a/salt/states/ssh_auth.py +++ b/salt/states/ssh_auth.py @@ -187,11 +187,14 @@ def present( else: # Split keyline to get key und commen keyline = keyline.split(' ') + key_type = keyline[0] + key_value = keyline[1] + key_comment = keyline[2] if len(keyline) > 2 else '' data = __salt__['ssh.set_auth_key']( user, - keyline[1], - keyline[0], - keyline[2], + key_value, + key_type, + key_comment, options or [], config) else: