fix(esxiagent): SSHKey was not unmarshalled correctly

This commit is contained in:
Rain
2020-02-26 20:12:47 +08:00
parent b40be2608b
commit 2d4cff4ef1
+1 -1
View File
@@ -246,7 +246,7 @@ func (as *SAgentStorage) AgentDeployGuest(ctx context.Context, data interface{})
rootPath := disks[0].(*esxi.SVirtualDisk).GetFilename()
key := deployapi.SSHKeys{}
err = dataDict.Unmarshal(&key, "desc")
err = dataDict.Unmarshal(&key)
if err != nil {
return nil, errors.Wrapf(err, "%s: unmarshal to deployapi.SSHKeys", hostutils.ParamsError.Error())
}