server: save SSH.PublicKey into user_vm_details regardless of password management (#3745)

Fixes: #3744

Signed-off-by: Kai Takahashi <k-takahashi@creationline.com>
This commit is contained in:
Kai Takahashi 2019-12-06 21:56:38 +09:00 committed by Rohit Yadav
parent e56fa31379
commit 6f3694c431

View File

@ -863,9 +863,8 @@ public class UserVmManagerImpl extends ManagerBase implements UserVmManager, Vir
userVm.setPassword(password);
//update the encrypted password in vm_details table too
encryptAndStorePassword(userVm, password);
} else {
_vmDao.saveDetails(userVm);
}
_vmDao.saveDetails(userVm);
if (vmInstance.getState() == State.Stopped) {
s_logger.debug("Vm " + vmInstance + " is stopped, not rebooting it as a part of SSH Key reset");