Skip to content

Commit

Permalink
External ip for byon - add ssh support
Browse files Browse the repository at this point in the history
  • Loading branch information
ivanayov committed May 23, 2017
1 parent f0c9dd6 commit 4ec5eb2
Showing 1 changed file with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -152,10 +152,14 @@ protected LocationSpec<? extends MachineLocation> parseMachine(Map<String, ?> va
Map<String, Object> machineConfig = MutableMap.copyOf(vals);

String osFamily = (String) machineConfig.remove(OS_FAMILY.getName());
String ssh = (String) machineConfig.remove("ssh");
if (machineConfig.containsKey("winrm") && !(machineConfig.get("winrm") instanceof String)) {
if (machineConfig.containsKey("ssh") && !(machineConfig.get("ssh") instanceof String)) {
machineConfig.put("address", machineConfig.get("ssh"));
machineConfig.remove("ssh");
} else if (machineConfig.containsKey("winrm") && !(machineConfig.get("winrm") instanceof String)) {
machineConfig.put("address", machineConfig.get("winrm"));
machineConfig.remove("winrm");
} else {
String ssh = (String) machineConfig.remove("ssh");
String winrm = (String) machineConfig.remove("winrm");

Map<Integer, String> tcpPortMappings = (Map<Integer, String>) machineConfig.get("tcpPortMappings");
Expand Down

0 comments on commit 4ec5eb2

Please sign in to comment.