mirror of https://github.com/apache/cloudstack.git
Fixed: unnecessary regeneration of SSH keys in developer mode when they already existed. (#12059)
This commit is contained in:
parent
bb8e7d39e6
commit
bac3421da4
|
|
@ -614,7 +614,7 @@ public class ConfigurationServerImpl extends ManagerBase implements Configuratio
|
|||
}
|
||||
// FIXME: take a global database lock here for safety.
|
||||
boolean onWindows = isOnWindows();
|
||||
if(!onWindows) {
|
||||
if (!onWindows && !(privkeyfile.exists() && pubkeyfile.exists())) {
|
||||
Script.runSimpleBashScript("if [ -f " + privkeyfile + " ]; then rm -f " + privkeyfile + "; fi; ssh-keygen -t ecdsa -m PEM -N '' -f " + privkeyfile + " -q 2>/dev/null || ssh-keygen -t ecdsa -N '' -f " + privkeyfile + " -q");
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue